Setting a checkbox
I have run into a problem in Test Partner where I am not able to set a checkbox found in the first column, first row of a JavaTable. I recorded the instruction but during playback I am getting an error. I feel this should be set programmatically in VBA and I tried the following:
Set t = JavaTable("Index=1").Items
Set o = t(1)
Dim chb As TCheckBox
chb = o.Item(1)
I get the following error:
Runtime error: 91
Object variable or with block variable not set
In short I am trying to get a reference to the checkbox control located in the 1st column, 1 row of a JavaTable. Can someone help me with this?
Re: Setting a checkbox
It may be that chb is not being Set and is still Nothing. Therefore, it does not have an Item method and raises an error.
Try changing the line to "Set chb = o.Item(1)" and see if that sorts it.