Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VB code
Message
From
14/03/2003 11:06:55
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
VB code
Miscellaneous
Thread ID:
00765891
Message ID:
00765891
Views:
42
I would like to write these codes in VB

1 – open a VFP table (independent table and table in a database)
if not used(“mytable”)
use mytable in 0
endif
select mytable

2 – search a record in a table
locate for xfield=xvar
if found()
endif

3 – Write in a table
replace xfield with xvar

4 – name of the computer
xmac=alltr(sys(0))
xmac=upper(alltr(substr(xmac,1,at('#',xmac)-1)))

5 – create a table or cursor
CREATE CURSOR csResult (field1 I)
CREATE table csResult (field1 I)

6 – scan a table
select mytable
scan
endscan

7 – does a file exist
if file(“c:\myfile.dbf”)
endif
Next
Reply
Map
View

Click here to load this message in the networking platform