I really do not know that is a negative answer an answer for your issues. I launch this post just only do not leave this issue without some answer since a long time, although it will be a negative one.
Briefly: You can not put the focus to a specific row in the grid.
(... by my best knowledge).
I had made some experiments after I read these type of issues, playing with "Set Control Focus" and/or "Get Grid Row", etc. system functions to find some solution. Unfortunatelly I haven't found any and I was also waiting and hoping curiously that somebody will tell some solution.
At last let me some observation:
1.) One relevant information could be that on what type of form do you want to do that.
2.) Another and always relevant information is your system configuration information, mainly your OneWorld release level (e.g. If I am right, "SetControlFocus" system function does not exist prior B733). Please, put them next time into your posts. Thanks.
I am really very sorry.
It was just mine "minus" two cents.
Click on it? Or if you want to process the line in ER you do the following;
Get Max Grid Rows(FC Grid, VA evt_mnMaxGridRecords_IA05)
While VA evt_mnGridCount_IA05 is less than or equal to VA evt_mnMaxGridRecords_IA05
Get Grid Row(FC Grid, VA evt_mnGridCount_IA05)
VA evt_mnGridCount_IA05 = [VA evt_mnGridCount_IA05]+1
// Do Some Things here
// To go to the Last record directly
Get Grid Row(FC Grid, VA evt_mnMaxGridRecords_IA05)
You are right how to process any row in ER but I am afraid that the original issue is not this.
I was looking for BSFNs that could issue keystroke simulation but unfortunately I haven't found any.
Maybe a solution could be:
1.) Set Control Focus to the grid with system function call.
2.) Issue keystrokes from ER to go HOME or END (CTRL+HOM, CTRL+END) to a fix starting point.
3.) Issue keystrokes from ER to reach the desired row (UP or DOWN).
The ONLY open question: how can we issue keystrokes from ER?
Does anybody know any BSFN, system function to perform it (I haven't found)?
Does anybody know any API to perform it?
Does anybody know the way how to write a C++ BSFN to perform it?
Could it work at all to issue keystrokes somehow from ER?
Any further idea to resolve K.J. Anand's and Ronnet's issue (supposly not only theirs)?
That is perfect for do something with the row, becouse the pointer is where
you need, but my case is diferent. I fill the grid row by row with insert
row grid buffer .... but theres a field the user have to complete, I want if
I filled the grid with 50 rows, the focus is positioned in that field in the
first row, so the user begin to complete all rows , instead the last row and
manualy have to move the cursor.