okbishop Posted December 24, 2010 Posted December 24, 2010 When I try to populate a citrix login window from within IE it does not work. I get both userid and password on the same first line where just userid goes. It's very frustrating. Here's the script #include <IE.au3> ; $oIE = _IECreate ("https://xxxxxxxxx.xxxxxxxxx.com/Citrix/Basic/site/default.aspx") WinWaitActive("[TITLE:Connect to xxxxxxxxx.xxxxxxxxx.com; CLASS:#32770; ]", "") ControlSend("TITLE:Connect to xxxxxxxxx.xxxxxxxxx.com", "", "[CLASS:Edit; ]", "N/A") ControlSetText("Connect to xxxxxxxxx.xxxxxxxxx.com", "", "[CLASS:Edit; ]", "N/A") Send("userid") ControlSetText("Connect to xxxxxxxxx.xxxxxxxxx.com", "", "[CLASS:Edit; INSTANCE:3]", "N/A") Send("password") So what am I missing.. Any ideas would be greatly appreciated. This is driving me crazy. Thanks
PsaltyDS Posted December 27, 2010 Posted December 27, 2010 Why didn't you specify INSTANCE for all of your EDIT control specifications? You should have something like "[CLASS:Edit; INSTANCE:1]" for user ID and "[CLASS:Edit; INSTANCE:2]" for password (actual instanced numbers vary). CLASS alone is only enough if you are sure there is only one control of that class present in the GUI. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
okbishop Posted December 27, 2010 Author Posted December 27, 2010 Ok. So that did not work. It just sits there and does not populate the script the first time I run it. Strange The second time I run it it does populate the login line with both the userid and password. So it's doing something. But any more suggestions would be great as I am stuck again. Thanks
PsaltyDS Posted December 27, 2010 Posted December 27, 2010 (edited) Why do you use ControlSetText() to put "N/A" in an edit and then use Send() to pass the actual data? If you have the correct identity for the edit control then just using ControlSetText() or ControlSend() is preferable to ever using Send(). If you really have to use Send() for some reason, then you should verify the control has focus with ControlSetFocus() ControlFocus().Edit: Corrected ControlFocus(). Edited January 23, 2011 by PsaltyDS Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
okbishop Posted January 23, 2011 Author Posted January 23, 2011 I don't think I am getting it. How would I use the ControlSetFocus(). I could not find any help listed on this. Thanks
Zedna Posted January 23, 2011 Posted January 23, 2011 I don't think I am getting it. How would I use the ControlSetFocus(). I could not find any help listed on this.ThanksIt's not so difficult to find it:ControlFocus() Resources UDF ResourcesEx UDF AutoIt Forum Search
okbishop Posted January 23, 2011 Author Posted January 23, 2011 Ok still not getting it to work. Is there an example somewhere that I could work off of that would help show me. That might be better than this way. Thanks
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