Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
AWOL grid...
Message
From
07/02/2002 06:02:04
 
 
To
06/02/2002 02:03:26
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Miscellaneous
Thread ID:
00615457
Message ID:
00616481
Views:
14
Hi!

Well, did you read the article?

Tip: to catch exact command where grid is reconstructed, put SET STEP ON command in the BeforeRowColChange event of the grid. BeforeRowColChange event of the grid is called each time before reconstruction. Remember that you need to clear the RecordSource property BEFORE any command that cause reconstruction.

HTH.

>Hi there,
>
>We tried that, but it didn't make any difference. Any other ideas??
>
>Thanks, Pablo
>
>
>
>>>Hi!
>
>This is a grid reconstruction behaviour.
>To fix it, set the Grid.RecordSource property to "" (empty string). Then restore it. So your program will look like:
>
>THisofrm.Grid1.RecordSource = ""
>* do refreshing, close alias and re-open it etc.
>...
>THisofrm.Grid1.RecordSource = "MyAlias"
>
>You can read more about grid recorstruction in FAQ#8019 and in VFP Grids Part I article in the August 2001 issue of the Universal Thread Magazine.
>
>HTH.
>
>
>>Can anyone explain what's just happened to my grid???
>>
>>I have a very very simple grid with 8 columns. I don't set the recordsource of the grid or the control source of each column until I need to...with the following code:
>>
>>IF USED("alsItem") THEN
>> USE IN alsItem
>>ENDIF
>>
>>USE lv_ClinicItem IN 0 ALIAS alsItem EXCLUSIVE
>>
>>thisform.grdItem.RecordSource="alsItem"
>>
>>Thisform.grdItem.grcItemNo.ControlSource="alsItem.cl_itemno"
>>Thisform.grdItem.grcDate.ControlSource="alsItem.cl_date"
>>etc...
>>
>>This has been working quite happily until an hour an a half ago when it decided to go bonkers. Specifically it started giving errors that the columns did not exist.
>>
>>We checked that the recordsource of the grid and controlsource of each column were blank and they were. We tried using a new grid...that didn't work. We checked that using a different view or table worked...they worked. We re-created the view....that didn't work.
>>
>>I've gone to my backup from lunchtime now, but I'd love to know (or have some idea at least) what caused this for future reference.
>>
>>Pablo
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Previous
Reply
Map
View

Click here to load this message in the networking platform