Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Multiuser app, second instance losing grid bindings
Message
From
20/11/2008 01:56:01
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP
Network:
Windows 2008 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01361877
Message ID:
01363059
Views:
13
>>>Kenneth,
>>>
>>>Don't use the root of c drive for your temp folder. Use a directory.
>>
>>changed to C:\TEMP
>>
>>Same problem.
>>
>>I found somewhere I was resetting the RecordSource to the cursor. I took this out and the references to the columns.
>>
>>So now I have this:
>>
>>Form Load Method: Creates blank cursor called CaseSQL
>>GRID Record Source is set to CaseSQL originally.
>>GRID columns are set with the appropiate fields from CaseSQL
>>
>>Now, run system on one machine and comes up fine.
>>Start on second machine and Grid comes up completely white.
>>
>>The recordsource is still there (CaseSQL) but the grid is completely blank.
>>
>>I am confounded. It must be me because I have done this many times before but I am besides myself at to why this now.
>
>Can you post code which is re-selecting records?
>
>Also you may want to grab all form's code using Class Browser View Code feature and look where you reference the grid. May be there is some strange code hidden somewhere.
>
>Finally, when you select records to your temp cursor, are you using NOFILTER clause? It may be important.

Yea, I thought of the NoFilter. Added to make sure but still the same.

I tested an old system and it is working fine.

Grid RecordSource is set to "CaseSQL"

The initialize function in LOAD method of the form is:
Select * from Event Where .F. into Cursor CaseSQL READWRITE NOFILTER       && create blank cursor

Select * from Event Into Cursor CaseSQL_X NOFILTER                                        && Get new values for cursor

Select CaseSQL
ZAP                                                                                                                  && clear out cursor
Append From CaseSQL_X                                                                                  && append new records
Use in CaseSQL_X                                                                                             && destroy temp cursor
Subsequent requeries use the same method of Selecting into a temp cursor (CaseSQL_X) and zapping and appending into the CaseSQL cursor.

Again, first run works fine. Second instance the Grid loses its columns (now I see that even Column1 does not exist).

Also, I am retracing an old system where this exact code is working on the same network.

Very confused.......
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform