Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Getting value from a table opened in a different DS
Message
 
 
To
11/03/2010 13:53:28
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Network:
Windows 2003 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01453599
Message ID:
01453991
Views:
40
>>Now I need to get value of the curTest.SomeField. I can not change MakeCursor method in any way.
>
>And you don't need to!
>
>Set DataSession To oAppObj.DataSessionId
>Select MyTable
>loRetData = Createobject('Empty')
>AddProperty( loRetData, 'records', Reccount() )
>If Reccount() > 0
>  AddProperty( loRetData, Textmerge( 'Row[<< reccount() >>]' ))
>  Scan
>    Scatter Name loRetData.Row[recno()]
>  Endscan
>Endif
>set datasession to this.DataSessionID
>messagebox( loRetData.Row[1].SomeField )
>
Cetin

The other constraint - the reason I started this thread - is to avoid switching datasessions.
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