Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


Is this possible?

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

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> Is this possible?
  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 >>
 Is this possible? - 2/27/2008 1:30:53 PM   
  yfki

 

Posts: 75
Score: 0
Joined: 12/12/2007
Status: offline
I know I can use the .Run method to hide a window.

Is ther anyway, trick, hack, workaround that could maybe be used to hide the DOS window spawned from the .Exec method.
It is very short-lived, but I would still prefer to either minimize or hide it.

Reason I am not using the .Run method, is I need to use the .WriteLine method to interface with Unix boxes..
Yes I know I can pass in commands from a txt file for pLink but I can't do that for reasons of Unix and Sudo SU Shell interaction.

Set objCmd = WshShell.Exec("%COMSPEC% /C " & pLinkCMD)
          objCMD.StdIn.WriteLine("cmd")
 
 
Post #: 1
 
 RE: Is this possible? - 2/27/2008 2:02:05 PM   
  dm_4ever


Posts: 2593
Score: 46
Joined: 6/29/2006
From: Orange County, California
Status: offline
Have you tried forcing your script to run using cscript.exe instead of wscript.exe....you should find example of that here.

_____________________________

dm_4ever

My philosophy: K.I.S.S - Keep It Simple Stupid
Read Me: http://www.visualbasicscript.com/m_24727/tm.htm
Frequently Asked Stuff: http://www.visualbasicscript.com/m_47117/tm.htm

(in reply to yfki)
 
 
Post #: 2
 
 RE: Is this possible? - 2/27/2008 5:20:40 PM   
  yfki

 

Posts: 75
Score: 0
Joined: 12/12/2007
Status: offline
Its being run inside of an .HTA

So even if I wanted to use something to change script engine to cscript, that would require access to the WScript object which as we all know .HTA does not allow.
Right now I am just using .Appactivate to bring the Window I prefer to the front. (I am ok with this solution)

However, I would still like to see if there is a workaround to somehow manage to hide the dos window completly.


      

or


      

(in reply to dm_4ever)
 
 
Post #: 3
 
 RE: Is this possible? - 2/28/2008 1:30:55 AM   
  ebgreen


Posts: 4613
Score: 31
Joined: 7/12/2005
Status: offline
Just to answer your initial question, there is no built in way to hide the window if you use .Exec.

_____________________________

"... when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick
Goog places to start:http://www.visualbasicscript.com/m_24727/tm.htm
http://www.visualbasicscript.com/m_47117/tm.htm

(in reply to yfki)
 
 
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 >> Is this possible? 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