mmaannddoo Posted August 9, 2013 Share Posted August 9, 2013 hey guys i need someone 2 help me in my program my program is sending a value i type in GUI and put it at a specific input this is my code #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <Constants.au3> #include <IE.au3> $hGUI = GUICreate( "New Window", 865, 255, -1, -1) $hPic = GUICtrlCreatePic( ".\Logo.jpg", 9, 11, 300, 219) $hInput = GUICtrlCreateInput("enter session key here", 323, 14, 530, 31) $hButton = GUICtrlCreateButton( "Send Session Key", 499, 92, 192, 54) GUISetState() Func run2() $oIE = _IECreate("the website") Local $oForm = _IEFormGetCollection($oIE, 0) $o_session_key = _IEFormElementGetObjByName($oForm, "session_key") _IEFormElementSetValue($o_session_key, $hInput) EndFunc While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $hButton run2() EndSelect WEnd this code is put number 4 in the website input Link to comment Share on other sites More sharing options...
Edano Posted August 9, 2013 Share Posted August 9, 2013 (edited) $hinput is the control id of the input, 4. if you want the value typed in input, use guictrlread($hinput) cheers E Edit: the rest of the thread from here on is nonsense, or at least a bad comedy. --------------------------------------------------------------------------------------------------- Edited August 11, 2013 by Edano mmaannddoo 1 [color=rgb(255,0,0);][font="'comic sans ms', cursive;"]FukuLeaks[/color][/font] Link to comment Share on other sites More sharing options...
Queener Posted August 9, 2013 Share Posted August 9, 2013 (edited) as Edano said. But to be on the clear side you need to do this: send(guictrlread($hinput)) This code must be after your controlclick or however you want it to send it to - on the website input. so for example winactivation("test.exe", "") send("{TAB}") send(guictrlread($hinput)) this is not a real code; but to give you an example. Real code would have to deal with if win exists then do this; else open the program etc... Edited August 9, 2013 by asianqueen Msgbox(0, "Hate", "Just hate it when I post a question and find my own answer after a couple tries. But if I don't post the question, I can't seem to resolve it at all.") Link to comment Share on other sites More sharing options...
Edano Posted August 9, 2013 Share Posted August 9, 2013 (edited) as Edano said. But to be on the clear side you need to do this: send(guictrlread($hinput)) This code must be after your controlclick or however you want it to send it to - on the website input. so for example winactivation("test.exe", "") send("{TAB}") send(guictrlread($hinput)) this is not a real code; but to give you an example. Real code would have to deal with if win exists then do this; else open the program etc... . what ? NO ! Edited August 9, 2013 by Edano [color=rgb(255,0,0);][font="'comic sans ms', cursive;"]FukuLeaks[/color][/font] Link to comment Share on other sites More sharing options...
Queener Posted August 9, 2013 Share Posted August 9, 2013 I tested before post... Works fine with me. . what ? NO ! Msgbox(0, "Hate", "Just hate it when I post a question and find my own answer after a couple tries. But if I don't post the question, I can't seem to resolve it at all.") Link to comment Share on other sites More sharing options...
Edano Posted August 9, 2013 Share Posted August 9, 2013 I tested before post... Works fine with me. . with autoit ??? [color=rgb(255,0,0);][font="'comic sans ms', cursive;"]FukuLeaks[/color][/font] Link to comment Share on other sites More sharing options...
Queener Posted August 9, 2013 Share Posted August 9, 2013 yes... here's partial of my working code I have been using If WinActive($Title) Then ControlClick($Title,"","MozillaWindowClass1","Left",1,85,60) Send($Username,1) Send("{TAB}") ControlClick($Title,"","MozillaWindowClass1","Left",1,85,83) Send($Password,1) Send("{ENTER}") where $username and password is the gui code. Msgbox(0, "Hate", "Just hate it when I post a question and find my own answer after a couple tries. But if I don't post the question, I can't seem to resolve it at all.") Link to comment Share on other sites More sharing options...
Edano Posted August 10, 2013 Share Posted August 10, 2013 asianqueen, i hate to say that, but do you even uderstand the code posted in OP ? i would estimate it is far above your present capabilities, and what you suggest is far off. [color=rgb(255,0,0);][font="'comic sans ms', cursive;"]FukuLeaks[/color][/font] Link to comment Share on other sites More sharing options...
Queener Posted August 10, 2013 Share Posted August 10, 2013 (edited) correct me if i'm wrong. He/she created an input and whatever value is within the input of autoit to paste that value to web browser specific textbox/input. If this isn't what the OP is requesting then I'm way off... Otherwise, I'm just giving an idea to the OP to get started. Edited August 10, 2013 by asianqueen Msgbox(0, "Hate", "Just hate it when I post a question and find my own answer after a couple tries. But if I don't post the question, I can't seem to resolve it at all.") Link to comment Share on other sites More sharing options...
Edano Posted August 10, 2013 Share Posted August 10, 2013 no, your way off. please read the helpfile about _IE* functions. [color=rgb(255,0,0);][font="'comic sans ms', cursive;"]FukuLeaks[/color][/font] Link to comment Share on other sites More sharing options...
Kidney Posted August 10, 2013 Share Posted August 10, 2013 correct me if i'm wrong. He/she created an input and whatever value is within the input of autoit to paste that value to web browser specific textbox/input. If this isn't what the OP is requesting then I'm way off... Otherwise, I'm just giving an idea to the OP to get started. the OP says he wants to take information from the GUI and place it into an element of a website. you r going in the opposite direction. Link to comment Share on other sites More sharing options...
Blue_Drache Posted August 11, 2013 Share Posted August 11, 2013 What website are you trying ot automate, mmaannddoo? $oIE = _IECreate("the website") isn't helpful at all. Perhaps we can assist if you tell us which website? Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted August 11, 2013 Moderators Share Posted August 11, 2013 mmaannddoo,And here you are asking again about "session keys". Are you going to explain why you want to extract and send such a thing in this thread - or are you going to ignore my question a second time? M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Blue_Drache Posted August 13, 2013 Share Posted August 13, 2013 mmaannddoo, And here you are asking again about "session keys". Are you going to explain why you want to extract and send such a thing in this thread - or are you going to ignore my question a second time? M23 Somehow, I don't think he's going to respond, much less return. *Shrug* Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted August 13, 2013 Moderators Share Posted August 13, 2013 Blue_Drache,I agree - so....... M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Recommended Posts