Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QTP: WebEdit : How to check if values in list are disabled.
#1
Not Solved
I am testing a form, where I randomly pick the value in a webedit box "address type".

Some values are disabled (greyed out) depending on what the user already has. (See attached for sample)

I am trying to find out how I can check if a value in the list is disabled because it seems that I am able to select the value even though it's disabled. This will cause a problem when saving the record.

Code below where i select the value randomly for the webedit box:

Code:
AddressTypeArray = Browser("Address: New - Microsoft").Page("Address: New - Microsoft").Frame("Frame").WebList("addresstypecode").GetROProperty ("all items")
CountAddressTypeArray= Browser("Address: New - Microsoft").Page("Address: New - Microsoft").Frame("Frame").WebList("addresstypecode").GetROProperty("items count")

Randomize
    AddressType = vbNo
    AddressTypeArray=Split(AddressTypeArray, ";")
    AddressType = RandomNumber (0,CountAddressTypeArray-1)
Wait 2
Browser("Address: New - Microsoft").Page("Address: New - Microsoft").Frame("Frame").WebList("addresstypecode").Select AddressTypeArray (AddressType)

Any help or advise would be appreciated.
Thanks!


Attached Files Image(s)
   
Reply


Messages In This Thread
QTP: WebEdit : How to check if values in list are disabled. - by katdean - 07-26-2011, 08:37 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Is VBScripting disabled in Office 365 update? soumyarani 0 1,513 12-19-2020, 12:37 PM
Last Post: soumyarani
Sad How To Find Dropdown Object based on Values from the dropdown list mesg2anil 12 33,926 12-19-2017, 10:25 PM
Last Post: sandy2404
  Trying to create List box in excel sheet at Run time with values yes No JACKSPARROW 0 1,685 01-17-2017, 11:05 AM
Last Post: JACKSPARROW
  Compare second web list value according to the first web list value roselin6 1 2,812 10-07-2015, 09:14 PM
Last Post: supputuri
  QTP identifying WebList as WebEdit and an Element passion77 3 8,386 01-27-2014, 10:21 PM
Last Post: supputuri

Forum Jump:


Users browsing this thread: 1 Guest(s)