Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


WScript Error

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

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> WScript Error
  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 >>
 WScript Error - 11/2/2004 10:30:20 PM   
  networknovice

 

Posts: 1
Score: 0
Joined: 11/2/2004
From:
Status: offline
Hi,
I could execute the following script in my local machine whereas if I send the html page as an attachment to my friends, they couldn't execute this html page from outlook.If they save it to the local harddisk the html page is getting executed.

<script type="text/vbscript">
dim wshNetwork
dim User
set wshNetwork = CreateObject("WScript.Network")
dom = wshNetwork.Userdomain
Compname = wshNetwork.computername
User = wshNetwork.Username 'to extract the network username
msg1=msgbox ("Computername: "& Compname+chr(13)&chr(10)+"Domain name: "&dom,vbinformation,"Domain and Computer name")
msgbox "Username: "&User
dattimemsg=msgbox ("Date: " &date &" Time: " & time,vbonly, "Date and Time")
set wshnetwork=nothing
</script>

Note: The error reported if executed by double clicking from the email is:

ActiveX Component can't create object: 'WScript.Network'

What shall I do to execute this code? It is urgent.Kindly reply asap.
 
 
Post #: 1
 
 Re: WScript Error - 11/2/2004 11:23:27 PM   
  mbouchard


Posts: 1916
Score: 16
Joined: 5/15/2003
From: USA
Status: offline
This is possibly a security setting with Outlook.

(in reply to networknovice)
 
 
Post #: 2
 
 
 
  

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 >> WScript Error 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