in reply to use Win32::IEAutomation;
I am not sure, but you should try using a conditional to check if it returns a true value. You enabled the -w flag and use strict, I trust, so the below code may help with debugging:
use diagnostics; if( my $textbox = $ie->getTextBox('name:', 'ctl00$ContentPlaceHolderCo +ntent$FileUpload_opfFile') ) { #Okay, now see if we can set the value if( $textbox->SetValue('C:\\test\\9780547076034NIMAS.opf') ) { print "it should work\n"; } else { print "could not set the value\n"; } } else { print "could not get the text box\n"; }
Be advised that I am unfamiliar with this module, and the getTextBox and SetValue methods may operate in void context, causing this test to be useless.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: use Win32::IEAutomation;
by sharief (Novice) on Dec 29, 2011 at 10:41 UTC | |
by thomas895 (Deacon) on Dec 29, 2011 at 20:06 UTC |