Sign in to follow this  
Followers 0
Annonyreeder

Help with forms and source code please

2 posts in this topic

Hi, this is a little similar to my last post but is actually different,

Ive been writing a script that displays a GUi, you can then select buttons on that GUI and it will wait 2000 Mili seconds then 'send' the information where you clicked (In this case it’s in a description box), I recently learnt about _IE functions, i made a few test scripts with google/yahoo and a few login pages (hotmail,gmail) these have all worked brilliantly, however when i try an implement this into my script its giving me error message, below is the source code and an example of the script im using, Thanks for any help :)

Script im using:

#include <IE.au3>
$oIE = _IECreate()
_IENavigate($oIE, "[url="http://172.30.238.40/CAisd/pdmweb.exe"]http://172.30.238.40/CAisd/pdmweb.exe[/url]")
$oForm = _IEFormGetCollection($oIE, "main_form")
$oQuery = _IEFormElementGetObjByName($oForm, "USERNAME")
$oQuery2 = _IEFormElementGetObjByName($oForm, "PIN")
_IEFormElementSetValue($oQuery, "place your search string here")
_IEFormElementSetValue($oQuery2, "place your search string here")
_IEFormSubmit($oForm)
_IELoadWait($oIE)
Exit

When using im getting the following error messages;

--> IE.au3 V2.4-0 Warning from function _IEFormGetCollection, $_IEStatus_NoMatch

--> IE.au3 V2.4-0 Error from function _IEFormElementGetObjByName, $_IEStatus_InvalidDataType

--> IE.au3 V2.4-0 Error from function _IEFormElementGetObjByName, $_IEStatus_InvalidDataType

--> IE.au3 V2.4-0 Error from function _IEFormElementSetValue, $_IEStatus_InvalidDataType

--> IE.au3 V2.4-0 Error from function _IEFormElementSetValue, $_IEStatus_InvalidDataType

--> IE.au3 V2.4-0 Error from function _IEFormSubmit, $_IEStatus_InvalidDataType

Source code:

Posted Image

Thanks again for your help guys, im doing really well with this project and couldn't of got this far without you, and yes that in the bottom right is my GUI :P:)

Share this post


Link to post
Share on other sites



hi,

i dont think you need the  _IEFormGetCollection in your code.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0