Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Alternate to Rename command
Message
From
10/10/2005 09:39:26
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
10/10/2005 09:36:45
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01057642
Message ID:
01057643
Views:
10
>Is there an alternate way to 'Rename' a file other than Rename command? I need somthing that will return a value as to wheather it worked or not, or haow to trap for errors and return a message to user. I have error trapping that logs the error and returns control backto the program but the user never knows the routine failed. This happens when the renamed from file is open or the rename file to already exists.

Doesn't ON ERROR work in this case?
llError = .F.
on error llError = .T.
(do some command)
if llError ...
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform