Website Login
Posted: Sat Jan 14, 2012 3:32 pm
I'm building a kind of a auto-cliker program and didn't found any working code. Can someone help or show me where find this?
Thank you in advance.
Thank you in advance.
Code: Select all
Procedure WebGadget_SetFieldText (nGadget, sFieldName.s, sValue.s)
Protected sScript.s
;sScript = "document." +sForm + "." + sFieldName + ".value = " + sValue + ";"
sScript = "var elements = document.getElementsByName('"+ sFieldName + "');"
sScript + "for (var i = 0; i < elements.length; ++i)"
sScript + "{"
sScript + "if (elements[i].tagName.toLowerCase() == 'input')"
sScript + "{"
sScript + "elements[i].value='" + sValue + "';"
sScript + "break;"
sScript + "}"
sScript + "}"
WebGadget_ExecScript (nGadget, sScript)
EndProcedure