Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Help with a Foxpro programming question
Message
From
09/09/2000 13:15:34
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00414601
Message ID:
00414610
Views:
21
>So Cetin if I understand correctly I write the code just as I see it because they are built in Foxpro functions ? To make this simpler ny table is called California, and all the files I want to append are stored in C:\data. Is it possible you could write it one time using my table and my directory so I can see it in your code and understand it better. I am just past being a beginner in Foxpro programming.
>
>Thank you very much.
>
>
>Phil


OK Phil,
In command window type as is :

Modify command _AppendFiles

A code window will appear. There copy and paste :
lparameters tcPath
local lnFiles, ix
m.lnFiles = adir(aTextFiles, m.tcPath+'*.txt')
for m.ix =  1 to m.lnFiles
 wait window nowait 'Appending : '+m.tcPath+aTextFiles[m.ix,1] 
 append from (m.tcPath+aTextFiles[m.ix,1]) delimited with character :
endfor
wait clear
Now press Ctrl+W to save (or click 'X' and answer yes to save)

From command window type as is :

clear all
use ?

Fox would popup a dialog box for you to choose a table. Locate and choose 'California.dbf'. As you choose cursor would retun to command window. Now exactly type as is :

_AppendFiles('c:\data\')

That's all.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform