Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


Error 0x80041002 (null)

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,62261
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> Error 0x80041002 (null)
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 Error 0x80041002 (null) - 7/9/2008 1:43:02 AM   
  Redwood_Lenny

 

Posts: 2
Score: 0
Joined: 7/9/2008
Status: offline
Hi all,

I am working on a script to clear the infamous OKLnn folder but I've run into a little problem.  I can pull the path from the registry but when I try to use that variable in the ExecQuery I get an error.
Here's the script.


      

And heres the error.
Line: 22
Char: 1
Error: 0x80041002
Code: 80041002
Source: (null)

Thanks in advance for the help.

RL
 
 
Post #: 1
 
 RE: Error 0x80041002 (null) - 7/9/2008 2:30:44 AM   
  Rischip


Posts: 502
Score: 2
Joined: 3/26/2007
Status: offline
The problem is the trailing slash from the directory you are pulling from the registry.


      

_____________________________

Rischip
Author of - The Grim Linker

(in reply to Redwood_Lenny)
 
 
Post #: 2
 
 RE: Error 0x80041002 (null) - 7/9/2008 2:43:37 AM   
  yehudah

 

Posts: 4
Score: 0
Joined: 7/9/2008
Status: offline
the script i wrote clean the content of all the files in the folder

but you can change this line:
objFSO.DeleteFile(strpath & "*.*"), DeleteReadOnly

to this one
objFSO.DeleteFile(strpath & "*.pdf"), DeleteReadOnly


      


_____________________________

http://vbsondemand.blogspot.com/

(in reply to Rischip)
 
 
Post #: 3
 
 RE: Error 0x80041002 (null) - 7/9/2008 3:07:10 AM   
  Redwood_Lenny

 

Posts: 2
Score: 0
Joined: 7/9/2008
Status: offline
quote:

ORIGINAL: Rischip

The problem is the trailing slash from the directory you are pulling from the registry.



Your added code works perfectly!
Thanks a million.

(in reply to Rischip)
 
 
Post #: 4
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> Error 0x80041002 (null) Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts