Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
GO EOF() Does Not Work
Message
 
To
15/07/1998 21:11:14
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00117869
Message ID:
00118245
Views:
22
>>I need to put a table at EOF() upon using it. What is the syntax for this? I've tried GO EOF() and about every variation I can think of, but I'm not getting it. I know it's probably something real simple. GO BOTTOM doesn't help, because I want to be able to open up a form with all blanks instead of opening up with the pointer pointing to a record. Thanks, CH.
>
>Heres a procedure which does it properly under a wide variety of circumstances...
>
*!***********************************************
>*!
>*! Procedure: GOEOF
>*!
>*!***********************************************
>PROCEDURE GoEOF
>LPARAMETER sel
>* Usage: GoEOF("tablename"), parameter is optional.
>IF EMPTY(m.sel)
> m.sel= SELECT()
>ENDIF
>IF ! EOF(m.sel)
> LOCAL setFilt, setDel
> setFilt= FILTER(m.sel)
> setDel= SET('Deleted')
> SET DELETED OFF
> IF EMPTY(m.setFilt)
> GO BOTTOM IN (m.sel)
> SKIP IN (m.sel)
> ELSE
> LOCAL oldSel
> oldSel= SELECT()
> SELECT (m.sel)
> SET FILTER TO
> GO BOTTOM
> SKIP
> SET FILTER TO &setFilt
> SELECT (m.oldSel)
> ENDIF
> IF m.setDel = 'ON'
> SET DELETED ON
> ENDIF
>ENDIF
><\PRE>
>HTH

Thanks.
Chuck Henry
Previous
Reply
Map
View

Click here to load this message in the networking platform