| View previous topic :: View next topic |
| Author |
Message |
thomas Newbie
Joined: 15 Jan 2003 Posts: 23 Location: Germany
|
Posted: Tue Jan 21, 2003 7:29 am Post subject: oppress Windows error message |
|
|
Hello,
When I try to delete a File that is in use, I get an error message from Microsoft NT (The file cannot delete...). Is it possible to oppress this message by dialogscript?
I use the syntax "file delete,path".
Thanks!! |
|
| Back to top |
|
 |
Tsunami1988 Contributor


Joined: 15 Aug 2002 Posts: 70 Location: The Netherlands
|
Posted: Tue Jan 21, 2003 11:07 am Post subject: Re: oppress Windows error message |
|
|
| thomas wrote: | Hello,
When I try to delete a File that is in use, I get an error message from Microsoft NT (The file cannot delete...). Is it possible to oppress this message by dialogscript?
I use the syntax "file delete,path".
Thanks!! |
The message is already oppressed, unless you use SHOWERRORS. |
|
| Back to top |
|
 |
thomas Newbie
Joined: 15 Jan 2003 Posts: 23 Location: Germany
|
Posted: Tue Jan 21, 2003 2:43 pm Post subject: oppress Windows error message |
|
|
I thought so too, but it does not work - the message will also shown if i use not showerrors. The message are not show by win2000 or winXP, only on NT Clients.
I think this is a bug. |
|
| Back to top |
|
 |
Skit3000 Admin Team

Joined: 11 May 2002 Posts: 2166 Location: The Netherlands
|
Posted: Tue Jan 21, 2003 3:01 pm Post subject: |
|
|
Try something like:
| Code: | %%file = filename
list create,1
list add,1,delete %%file
list savefile,1,delete.bat
runh delete.bat,WAIT |
In that case you wont get an error. Check with @file() if the file is deleted... |
|
| Back to top |
|
 |
thomas Newbie
Joined: 15 Jan 2003 Posts: 23 Location: Germany
|
Posted: Tue Jan 21, 2003 3:13 pm Post subject: |
|
|
| I do NOT want an error message. I want also do not want to use .bat files, i only want to use vds-Script. |
|
| Back to top |
|
 |
Tsunami1988 Contributor


Joined: 15 Aug 2002 Posts: 70 Location: The Netherlands
|
Posted: Tue Jan 21, 2003 5:10 pm Post subject: |
|
|
| thomas wrote: | | I do NOT want an error message. I want also do not want to use .bat files, i only want to use vds-Script. |
Then you should upgrade to 2000/XP  |
|
| Back to top |
|
 |
Skit3000 Admin Team

Joined: 11 May 2002 Posts: 2166 Location: The Netherlands
|
Posted: Tue Jan 21, 2003 6:38 pm Post subject: |
|
|
Good one!  |
|
| Back to top |
|
 |
Garrett Moderator Team
Joined: 04 Oct 2001 Posts: 2149 Location: A House
|
Posted: Tue Jan 21, 2003 8:32 pm Post subject: |
|
|
Only suggestion I can think of, is to find out which program is using the
file, and have your program shut down the other program, and then
delete the file.
-Garrett |
|
| Back to top |
|
 |
Dr. Dread Professional Member


Joined: 03 Aug 2001 Posts: 1065 Location: Copenhagen, Denmark
|
Posted: Wed Jan 22, 2003 6:43 am Post subject: |
|
|
Another thing to think of when deleting files on NT4 systems: Don't try to delete files
which aren't there - that'll generate error messages as well. That's not the case on XP/2K boxes.
So instead of just
use something like
| Code: | if @file(%%%%file)
FILE DELETE, %%file
end |
Greetz
Dr. Dread _________________ ~~ Alcohol and calculus don't mix... Don't drink and derive! ~~
String.DLL * advanced string processing |
|
| Back to top |
|
 |
Tsunami1988 Contributor


Joined: 15 Aug 2002 Posts: 70 Location: The Netherlands
|
Posted: Wed Jan 22, 2003 4:33 pm Post subject: |
|
|
That still doesn't fix the problem
| Dr. Dread wrote: |
| Code: | if @file(%%%%file)
FILE DELETE, %%file
end |
|
hmmm, a little much of the %'s  |
|
| Back to top |
|
 |
Dr. Dread Professional Member


Joined: 03 Aug 2001 Posts: 1065 Location: Copenhagen, Denmark
|
Posted: Wed Jan 22, 2003 7:44 pm Post subject: |
|
|
| Tsunami1988 wrote: | That still doesn't fix the problem  |
I know, it was sort of a comment for another NT issue...
| Tsunami1988 wrote: | hmmm, a little much of the %'s  |
He-he, i guess I got a little carried away
Greetz
Dr. Dread _________________ ~~ Alcohol and calculus don't mix... Don't drink and derive! ~~
String.DLL * advanced string processing |
|
| Back to top |
|
 |
MarkTrubo Contributor


Joined: 27 May 2001 Posts: 148 Location: Long Island, NY
|
Posted: Thu Jan 23, 2003 12:57 am Post subject: |
|
|
| I'm pretty sure I delete files all the time with VDS on NT -- of course the programs are in my office, so I forgot how to do it now that I am at home. I'll check and post the answer. |
|
| Back to top |
|
 |
moke Contributor

Joined: 02 Jan 2002 Posts: 162
|
Posted: Thu Jan 23, 2003 5:31 pm Post subject: |
|
|
I've had similar problems on NT and it ususally comes down to 1 of 3 things.
1) The file doen't exist. As Dread already pointed out 2000/XP and 95/98
do not generate an error but NT does so If @file would help
2) The profile the app is running as doesn't have sufficient rights to
delete the file.
3) The file is open and cannot be deleted. In which case you need to KILL
the app that has the file open. I think you use "run KILL -f filename"
(your app must have rights to do this). You can check the Task Manager
applications or processes to try and narrow down what has the file open
if you are unsure.
moke |
|
| Back to top |
|
 |
MarkTrubo Contributor


Joined: 27 May 2001 Posts: 148 Location: Long Island, NY
|
Posted: Thu Jan 23, 2003 5:42 pm Post subject: |
|
|
| Yup, I checked my programs and all -- Moke is right on the money with all three! |
|
| Back to top |
|
 |
|