Webs Posted November 20, 2009 Share Posted November 20, 2009 So below is a section of my script I'm having problems with. I was wondering if someone knew how to send a string variable to a command prompt. I think I know how to open a command prompt, but wanted to send a variable to said prompt for debugging purposes. The variable I am trying to pull the string from is "$WindowTitle". Any help would be greatly appreciated. #include <IE.au3> ;Open IE, go to Foundstone webpage with the following parameters: 0=opens webpage, 1=visible, 1=_ieloadwait $oIE = _IECreate("https://fdxfse2.jdnet.deere.com/",0,1,1) ;Accept Certificate from Windows Security popup ;Func Sleep(3000) While 1 $WindowTitle = WinGetTitle("","") Select Case $WindowTitle = "Security Alert" WinActivate("Security Alert","") ControlClick("Security Alert","","Button1") Case $WindowTitle = "Choose a digital certificate" WinActivate("Choose a digital certificate","") ControlClick("Choose a digital certificate","","Button3") Case $WindowTitle = "Certificate Error: Navigation Blocked" WinActivate("Certificate Error: Navigation Blocked","") _IEImgClick ($oIE, "red_shield.png", "src") ExitLoop EndSelect WEnd ;EndFunc ShellExecute('"C:\Documents and Settings\' & @UserName & '\Start Menu\Programs\Accessories\Command Prompt"') Link to comment Share on other sites More sharing options...
jvanegmond Posted November 20, 2009 Share Posted November 20, 2009 Send($WindowTitle) github.com/jvanegmond Link to comment Share on other sites More sharing options...
Webs Posted November 20, 2009 Author Share Posted November 20, 2009 Send($WindowTitle) LOL... Somehow I thought it might be that simple. Thanks a ton Manadar. Link to comment Share on other sites More sharing options...
jvanegmond Posted November 20, 2009 Share Posted November 20, 2009 No problem. Happy programming. github.com/jvanegmond Link to comment Share on other sites More sharing options...
Webs Posted November 20, 2009 Author Share Posted November 20, 2009 To anyone who happens to come across this, I found a better way to do what I was doing, which is essentially debugging: ;MsgBox ( 1, "Title", VariablName) Link to comment Share on other sites More sharing options...
AndyG Posted November 20, 2009 Share Posted November 20, 2009 (edited) if you work with Scite, you could easy use the CTRL+SHIFT+D or ALT+d or explore the other "debug"-tools in the "Extras"-menu a nice abbreviation is to type mb2 in scite and after that the space-key. there are much more abbreviations listed in the abbrev.properties in the "Options"-menu Edited November 20, 2009 by AndyG Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now