Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Grid control methods
Message
From
02/08/1999 14:38:21
 
 
To
01/08/1999 11:43:22
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00248392
Message ID:
00248944
Views:
13
>>>>I have figured out thanks to this group how to repopulate my grid after making changes to it source.
>>>>However how can I get the controls (grid1.column1.texbox1, etc)their methods back? (I have the textbox.click refreshing the form)
>>>
>>>It seems that VFP simply doesn't like you changing the .RecordSource, even if it is the same view/cursor name with new values but the same definition of columns. We've created a self building grid that will check to see if the custom textbox we typically use is still there. If not, as VP tends to want to revert to Text1, then we have code that removes .Text1 and does an .Addobject() to the column to add our custom textbox class. This preserves the code in the custom textbox making it available for use.
>>>
>>>Steve
>>
>>I've rebuilt most of the grid anyway I'll try that
>>Thanx
>
>I may not understand, but its my belief that your .grid.textbox.click event will stick around if you set the recordsource property to '' before you make changes to the underlying table, and then set the recordsource property back after you are done. Please test that and tell me how you make out.

For those who might be following this tread, What I ended up doing since all the method in the grid was for was to update the picture on the screen was to call the refresh method from both the keystroke and click on the form.
Previous
Reply
Map
View

Click here to load this message in the networking platform