Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Selected Item in Grid
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00338631
Message ID:
00339171
Views:
16
Hi Alan,

Thanks for your reply. So, if I put the method LocatedRecordOnTop to my grid subclass, may I put you as an other?

Thanks again.

>I found a couple of solutions but this one is the easiest:
>
>>If x is the RECNO() of the record I want to appear at the top of the grid, how do I force the grid to scroll up or down so that row is at the top?
>
>this one is easy to manage, make an new method for the grid:
>**************************************************************
>THISFORM.LockScreen=.T.
>nHeight = THIS.Height
>THIS.Height = THIS.HeaderHeight + THIS.RowHeight
>THIS.Refresh
>THIS.Height=nHeight
>THISFORM.LockScreen=.F.
>***************************************************************
>
>
>>You're welcome. So, did you finally come up to a solution? Could you describe it, because I may be interested too...
>>
>>>Thanks Nadya.
>>>
>>>>Hi Alan,
>>>>>>>
>>>>>>>If I read you right and you want to be looking at the 1st record in the table when the grid is populated. Do this before you display the grid
>>>>>>>
>>>>>>>SELECT your_table
>>>>>>>GO TOP
>>>>>>>
>>>>>>>This was all I needed to solve the problem when I was looking at the last record
>>>>>>>
>>>>>>>HTH
>>>>>>>Mike
>>>>>>
>>>>>>Hi Mike,
>>>>>>No, that's not what I mean. I display a grid after I do a Locate. When the grid displays, the record that was found is in the bottom row of the grid. I want it to be in the top row with all of the other records that follow, under it.
>>>>>>
>>>>>You may want to scroll to your record while thisform.LOCKSCREEN=.t. in your search method. I believe Catin or Marcia described this in thier messages. Try to search here in UT for their messages and I'll try to do this also.
>>>>
>>>>Ok, try thread Visual FoxPro in general Re: Grid Behavior Thread #319786 Message #319845
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform