Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CURSORSETPROP and No Table is Open error
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
CURSORSETPROP and No Table is Open error
Miscellaneous
Thread ID:
00017439
Message ID:
00017439
Views:
92
If I have the following code in the LostFocus event of a text box, and I type numbers in the text box and press tab, the code does exactly what I want. However, if I pass the value of p_claimno from a diffent form, I get an error on the CURSORSETPROP: No Table is Open. I've tried puting the code in the Init event of the form, and also leaving it in the LostFocus event of the textbox, but I can't get it to work. What am I doing wrong?

p_claimno = VAL(thisform.txtClaimNumber.Value)
SET MULTILOCKS ON
=CURSORSETPROP("Buffering", 4, 'TTD_Payments')
=CURSORSETPROP("Buffering", 4, 'TPD_Payments')
SET EXACT OFF
SET ORDER TO 1
SEEK p_claimno
IF FOUND( )
thisform.refresh()
ThisForm.txtDateFrom.SetFocus
ELSE
cMessageTitle = 'Claim Number Not Found'
cMessageText = 'Record not found. Would you like to try again?'
nDialogType = 4 + 32 + 256
* 4 = Yes and No buttons
* 32 = Question mark icon
* 256 = Second button is default

nAnswer = MESSAGEBOX(cMessageText, nDialogType, cMessageTitle)

DO CASE
CASE nAnswer = 6
WAIT WINDOW 'You chose Yes'
CASE nAnswer = 7
WAIT WINDOW 'You chose No'
ENDCASE
ENDIF
Next
Reply
Map
View

Click here to load this message in the networking platform