Sign in to follow this  
Followers 0
redpicker

How to find object properties

2 posts in this topic

I'm working on a script that interfaces with a canned MRP program that maintains our Part Numbers. It has a IE interface.

In playing around, I've found that the information I am interested in is in Frame 10 (that was a big discovery).

I've discovered that Frame 10 has 72 inputs

I use this code

$oInputs = _IETagNameGetCollection ($oFrame10, "input")
$iNumInputs =@extended
MsgBox(0,"Input Info", "Frame has" & $iNumInputs & " inputs")
ReDim $aInput [$iNumInputs+1][4]
$aInput[0][0] = "Type"
$aInput[0][1] = "ID"
$aInput[0][2] = "Value"
$i=1
For $oInput In $oInputs
    $aInput[$i][0] = $oInput.type
    $aInput[$i][1] = $oInput.id
    $aInput[$i][2] = $oInput.value
    $aInput[$i][3] = $oInput.status
    $i = $i + 1
Next
_ArrayDisplay($aInput)

Now, I got the "type" property from looking through the help file

(I'm guessing that the term "property" is correct, that is, $aInput[$i][0] is given the "type" property of the object $oInput, which turns out to be either "test", "hidden", or "checkbox".

I guessed on the "id" property. It seems to be what I would call a field name, with values like "nrOfRows"

I guessed on the "value" property. It returns the text displayed in inputs of type "text"

I guessed on the "status" property, since some of the text inputs are active (editable, enables, whatever you want to call it) and others are greyed-out. I wanted to determine if an input was either active or greyed-out, but it doesn't do anything, it allways returns "0".

Other things I have tried result in an error.

Is there a list of possible, for lack of a better term, "properties" that an input object can have?

I hope make some sense. I am not very good at this, but I have been getting better.

redpicker

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