#35693 - 2003-01-27 08:55 AM
@error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
Hi, I'm using the following command to copy files in kix:
shell '%compsec% /e:1024 /c copy SOURCE DESTINATION'
and check @error for any errors. The funny thing is that on win2k it works fine, and @error returns non-zero if SOURCE doesn't exist, but in win95 the value returned by @error is zero.
Any ideas?
Thank you, V.F.
|
Top
|
|
|
|
#35697 - 2003-01-27 09:46 AM
Re: @error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
I need to know which error occured - I'd like to ignore share violation, but to treat all other errors. Dos copy returns different values for each error (for example 11 for share violation), but kix copy returns same value for all errors.
Thank you, V.F.
|
Top
|
|
|
|
#35699 - 2003-01-28 12:39 AM
Re: @error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
I get error value 2 both for sharing violation and for source file that doesn't exist.
Thank you, V.F.
|
Top
|
|
|
|
#35703 - 2003-01-28 08:22 AM
Re: @error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
By saying sharing violation, I mean that the file is in use by some application (like operating system), and copy tries to overwrite it.
In dos, in such cases error number 11 is returned, but in kix error value 2 is returned.
My problem is that kix copy returns 2 for other errors as well, like when source doesn't exist.
Thank you once again for your help, V.F.
|
Top
|
|
|
|
#35705 - 2003-01-29 10:19 AM
Re: @error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
I'm using kix 3.47. This problem occurs in win95 only (in win2k it works fine). Error 5 is for 'access denied', while error 11 is for 'sharing violation' - when the file is in use by the OS. There are no NTFS permissions in win95, so I can't get error 5.
Thanks, V.F.
|
Top
|
|
|
|
#35706 - 2003-02-02 08:02 AM
Re: @error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
Any ideas?
Thank you, V.F.
|
Top
|
|
|
|
#35708 - 2003-02-04 12:27 AM
Re: @error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
After making the target read only, I still get error 2.
Thanks, V.F.
|
Top
|
|
|
|
#35710 - 2003-02-04 04:52 PM
Re: @error
|
zz_vf_zz
Getting the hang of it
Registered: 2002-04-07
Posts: 53
|
Hi,
I tested it in ver 4.10, and now I get error 5 for both source that doesn't exist and sharing violation.
Thanks, V.F.
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 255 anonymous users online.
|
|
|