alex1122 Posted February 28, 2020 Posted February 28, 2020 (edited) I need to write Username and password with my selenium test in popup log , for this I use Auto it script: Sleep(3000) Send("DZC\yyyyyyyy") // Username Sleep(1000) Send("{Tab}") Sleep(1000) Send("xxxxxx") // Password Sleep(1000) Send("{Enter}") It works if I open browser with "hands" go to url and after that I run the script, in this statement it writes Username and password in necessary fields, but it doesn't works if I run my selenium test, so I have automatically opened link in google chrome, after that I run my AutoIT script, but it doesn't works. I think that, with "hands" and automatically opened browsers have differences. So, in my opinion I need to write in my script connection/navigation way to my opened browser login and password fields or something like that. As I understand it is impossible to write username and password, because if i open chrome browser and url using my selenium test "chrome is being controlled by automated test software" I home someone can help me! Edited February 28, 2020 by Jos
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 (edited) On 2/28/2020 at 2:56 PM, alex1122 said: I need to write Username and password with my selenium test in popup log , for this I use Auto it script: Sleep(3000) Send("DZC\yyyyyyyy") // Username Sleep(1000) Send("{Tab}") Sleep(1000) Send("xxxxxxx") // Password Sleep(1000) Send("{Enter}") It works if I open browser with "hands" go to url and after that I run the script, in this statement it writes Username and password in necessary fields, but it doesn't works if I run my selenium test, so I have automatically opened link in google chrome, after that I run my AutoIT script, but it doesn't works. I think that, with "hands" and automatically opened browsers have differences. So, in my opinion I need to write in my script connection/navigation way to my opened browser login and password fields or something like that. As I understand it is impossible to write username and password, because if i open chrome browser and url using my selenium test "chrome is being controlled by automated test software" I home someone can help me! Expand Edited February 28, 2020 by alex1122
Danp2 Posted February 28, 2020 Posted February 28, 2020 As written, your script will send the output to the currently active window, which may not be the browser. Suggest that you look at the WinActivate function. P.S. Also suggest that you change your password now that you've exposed it the the entire world. 😲 Musashi and seadoggie01 2 Latest Webdriver UDF Release Webdriver Wiki FAQs
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 On 2/28/2020 at 3:30 PM, Danp2 said: As written, your script will send the output to the currently active window, which may not be the browser. Suggest that you look at the WinActivate function. P.S. Also suggest that you change your password now that you've exposed it the the entire world. 😲 Expand Maybe you can write how it approximately looks?
Moderators JLogan3o13 Posted February 28, 2020 Moderators Posted February 28, 2020 (edited) @alex1122 Why would you report your own thread?? Also, as stated above, you need to edit your posts and remove the username and password. Not very smart to post that. Edited February 28, 2020 by JLogan3o13 "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
seadoggie01 Posted February 28, 2020 Posted February 28, 2020 You could probably take a look at using _WD_Alert() On 2/28/2020 at 3:56 PM, alex1122 said: Maybe you can write how it approximately looks? Expand Um... this isn't a coding service Try it and we're happy to help, otherwise find someone on Upwork or a similar site All my code provided is Public Domain... but it may not work. Use it, change it, break it, whatever you want. Reveal hidden contents My Humble Contributions:Personal Function Documentation - A personal HelpFile for your functionsAcro.au3 UDF - Automating Acrobat ProToDo Finder - Find #ToDo: lines in your scriptsUI-SimpleWrappers UDF - Use UI Automation more Simply-erKeePass UDF - Automate KeePass, a password managerInputBoxes - Simple Input boxes for various variable types
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 On 2/28/2020 at 3:57 PM, JLogan3o13 said: @alex1122 Why would you report your own thread?? Also, as stated above, you need to edit your posts and remove the username and password. Not very smart to post that. Expand How i can delete post or edit? Please
Moderators JLogan3o13 Posted February 28, 2020 Moderators Posted February 28, 2020 Ehhh, click the Edit link? "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 On 2/28/2020 at 4:01 PM, JLogan3o13 said: Ehhh, click the Edit link? Expand
Developers Jos Posted February 28, 2020 Developers Posted February 28, 2020 (edited) Not sure if this member is in the right group yet to allow the edit of a post ? (Edited the original post to get rid of the UID & PW) Jos Edited February 28, 2020 by Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
seadoggie01 Posted February 28, 2020 Posted February 28, 2020 (edited) @JLogan3o13 He's too new, no permissions yet 😐 Sorry, ninja-d Edited February 28, 2020 by seadoggie01 All my code provided is Public Domain... but it may not work. Use it, change it, break it, whatever you want. Reveal hidden contents My Humble Contributions:Personal Function Documentation - A personal HelpFile for your functionsAcro.au3 UDF - Automating Acrobat ProToDo Finder - Find #ToDo: lines in your scriptsUI-SimpleWrappers UDF - Use UI Automation more Simply-erKeePass UDF - Automate KeePass, a password managerInputBoxes - Simple Input boxes for various variable types
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 On 2/28/2020 at 4:03 PM, Jos said: Not sure if this member is in the right group yet to allow the edit of a post ? (Edited the original post to get rid of the UID & PW) Jos Expand Can you do the same with the first my post. Thanks
Developers Jos Posted February 28, 2020 Developers Posted February 28, 2020 Done, but check if you have the Edit in the meantime available as I see your group has changed. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Moderators JLogan3o13 Posted February 28, 2020 Moderators Posted February 28, 2020 On 2/28/2020 at 4:03 PM, Jos said: Not sure if this member is in the right group yet to allow the edit of a post ? (Edited the original post to get rid of the UID & PW) Jos Expand I changed his membership, not sure why it didn't save. I just did it again and it looks like it went through. @alex1122 apologies on the confusion, you should now be able to Edit your own posts. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
Nine Posted February 28, 2020 Posted February 28, 2020 Too late Alex I wrote them down ! I am just teasing you Danp2 1 “They did not know it was impossible, so they did it” ― Mark Twain Reveal hidden contents Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search in text (au3) files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector Printer Manager GIF Animation (cached) Debug Messages Monitor UDF Screen Scraping Round Corner GUI UDF Multi-Threading Made Easy Interface Object based on Tag
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 On 2/28/2020 at 4:09 PM, JLogan3o13 said: I changed his membership, not sure why it didn't save. I just did it again and it looks like it went through. @alex1122 apologies on the confusion, you should now be able to Edit your own posts. Expand Yes, now I have edit button)
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 Someone knows anything else how it is possible to manage with this problem? Thanks
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 Sleep(3000) Opt("WinTitleMatchMode",2) WinActivate("Google Chrome") Send("Username") Sleep(1000) Send("{Tab}") Sleep(1000) Send("Password Sleep(1000) Send("{Enter}") I use this construction, it put cursor on Username field, but but nothing else happens, it still doesn't write anything
Bert Posted February 28, 2020 Posted February 28, 2020 (edited) Do this and it is MUCH easier - see if you can use a custom crafted URL string to pass your ID and password. I do this all the time in passing data to forms on websites when I'm testing. Example: https://www.test.com?id=1234&pw=asdr Now don't use the example and expect it to work on your issue. You HAVE to get the field ID and put that in the URL string then the text you want to populate in that field. Edited February 28, 2020 by Bert The Vollatran project My blog: http://www.vollysinterestingshit.com/
alex1122 Posted February 28, 2020 Author Posted February 28, 2020 On 2/28/2020 at 4:42 PM, Bert said: Do this and it is MUCH easier - see if you can use a custom crafted URL string to pass your ID and password. I do this all the time in passing data to forms on websites when I'm testing. Example: https://www.test.com?id=1234&pw=asdr Now don't use the example and expect it to work on your issue. You HAVE to get the field ID and put that in the URL string then the text you want to populate in that field. Expand It is imposible to get field ID, because it is popup log
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