THanks! I don't want to wear out my stay on this thread. Some of the links in the thread you point me to are dead and I cannot get the info they refer to. In any case, I see that you mention not using IE at all, and that would be fine if I can do it that way. All I need to do is fetch the HTML result, like GetURL does, but pass in a form entry.
The form page has one input box named "empno" and the form tag calls "empinfo.asp" using "post". I tried the code below, but it doesn't work and causes the result to show an error due to failed SQL query.
Code:
Break On
Do
?"Enter search term> "
Gets $term
Until $term
$URL = "http://intranet.mycompany.com/empinfo.asp"
$IE = CreateObject("InternetExplorer.Application")
$IE.Visible = 1
$IE.Navigate($URL)
While $IE.Busy and $IE.ReadyState <> 4 and @ERROR = 0
Loop
$IE.Document.getElementById("empno").Value = $term
$IE.Document.getElementById("submit").Click()
Exit 0
I enter the the string value emp number and hit Enter and it does open the requested page but isn't passing in the parameter value properly. What am I doing wrong?
_________________________
silence is golden, but duct tape is silver