Hello
How would I go about getting the value of document.getElementbyId and copying it to my clipboard?
Thank you,
Ryan
Copy value from document.getElementbyId
Re: Copy value from document.getElementbyId
Replace "wb" with your web browser object name and "MyID" with the element ID:
Clipboard := wb.document.getElementById("MyID").Value
Clipboard := wb.document.getElementById("MyID").Value
Re: Copy value from document.getElementbyId
Thank you for that.
I use Chrome so would this work?
Clipboard := chrome.document.getElementById("pg:addCommentF:addCommentPB:rptOrder:1:emailCustomerPBS:emailCustomerPBSI:j_id93").innerText.trim().Value
I use Chrome so would this work?
Clipboard := chrome.document.getElementById("pg:addCommentF:addCommentPB:rptOrder:1:emailCustomerPBS:emailCustomerPBSI:j_id93").innerText.trim().Value
Re: Copy value from document.getElementbyId
Because what I have just now is I use this as an email template:
What I would like is for the value I get from document.getElementbyId to be pasted after "Hello" so then I don't need to type/copy+paste the name into the email.
Code: Select all
::#p::
Send, Hello {enter 4}
Send, If you're happy with this outcome, then you don't need to reply as the case will close automatically. {enter 2}
Send, If you feel this isn't resolved, please reply within 30 days and this will re-open the case back into my queue.{enter 2}
Send, Kind Regards{enter}
Send, Ryan Ayton
Return
Re: Copy value from document.getElementbyId
No, Chrome has no generic COM support. Either use use Internet Explorer (only browser which has it) or you will have to look into using the Selenium Webdriver with Chrome.I use Chrome so would this work?
Also, I doubt that you can use the javascript (?) function Trim() like this with COM in AHK... but you can trim the value you get with AHK.
Who is online
Users browsing this forum: NinjoOnline and 291 guests