Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error While USE Command
Message
From
23/01/2013 02:56:20
 
 
To
23/01/2013 02:25:04
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01563718
Message ID:
01563720
Views:
54
>Using the Following code, I am copying One Folder from Source to Destination Folder.
>
>LOCAL oShell, oSrcFolder, oDstFolder
>CreateDirectory('&Destinationfolder',0)
>oShell = CREATEOBJECT("Shell.Application")
>oSrcFolder = oShell.NameSpace('&sDirectory')
>oDstFolder = oShell.NameSpace('&Destinationfolder')
>
>IF VARTYPE(oDstFolder)="O" AND VARTYPE(oSrcFolder.Items)="O"
> oDstFolder.CopyHere(oSrcFolder.Items)
>ENDIF
>****************
>
>*Afterwards, I am Using
>
>Set Default to ('&Destinationfolder')
>Use ABC.DBF
>
>MY problem is while the copying process is Not yet completed the my next commands i,e Set Default to ('&Destinationfolder')
> & Use ABC.DBF are executed and an error ABC.DBF does not exist is generated.
>
>What is to be Done ?
>Regards
>Harsh

Unless you are able to determine whether the copying is done or not from a return value from the used objects, you must find another solution to this part of the job. That's how I see it.
Previous
Reply
Map
View

Click here to load this message in the networking platform