Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Create cursor in a particular work area
Message
From
04/11/2004 08:41:16
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00957814
Message ID:
00958049
Views:
13
>>Try
>>CREATE CURSOR crs_at3_temp (fname c(1))
>>USE DBF("crs_at3_temp") AGAIN IN 3 ALIAS crs_at3
>>? SELECT("crs_at3")
>>USE IN crs_at3_temp
>
>WOW! You guys are FAST!!! And with almost exactly the same code sample! I guess I have to give the stars to Serge since he wins by barely a minute! ;)
>
>Thanks both of you for the quick response! That code sample is exactly what I needed. Never thought of doing it that way!

ATTENTION, if the cursor it is created into the particular WA,
this code fails !
CLOSE TABLES ALL
CREATE CURSOR W1 (A i)
CREATE CURSOR W2 (A i)
SELECT 0
? 'WHERE THE CURSOR IT IS CREATED',SELECT()
CREATE CURSOR crs_at3_temp (fname c(1))
USE DBF("crs_at3_temp") AGAIN IN 3 ALIAS crs_at3
USE
? SELECT("crs_at3")
USE IN 3
solution:
#DEFINE PARTICULARWA 3
SELECT 0
CREATE CURSOR 'crs_at3'+IIF(SELECT()=PARTICULARWA,'','_') (fname c(1))
IF SELECT()#PARTICULARWA
	USE DBF() AGAIN IN PARTICULARWA ALIAS crs_at3
	USE
ENDIF
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform