Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to get the dynamic value displayed on the page
#1
Not Solved
Hi,

My web page displays the search results and a text at the top of the results table as " 100 records" , " 200 records"..etc.. basically the number of records returned from the Search,

Now I have to capture that text for my testing.

This text is mentioned in the table row inside the <TD> tag..

i was able to capture the web element from the Active screen for that element, but i am not sure which property to use to extract the value


The screen looks like this

--------------------------------------------------------------------
Summary 100 records
--------------------------------------------------------------------


Here is my code: this returns the value "Summary" but i am looking to get the value as "100 records"


Code:
txtstr1 = Browser("MDC").Page("MDC").Frame("mdma_bottom").WebElement("pgrSdpSummary:Page:ddlPage").GetROProperty("text")

any help??

Thanks,
Geetha
Reply
#2
Not Solved
hi Geetha,

i think the data i.e. Summary 100 records in displaing in the WebTable. If it is so, then we can handle the situation.

Please let me know whether that's a table or not, Based on your input i will provide the solution.
Thanks,
SUpputuri
Reply
#3
Not Solved
Hi King,
Could u please tell me , how to fetch the dynamic values from the web page and please see the attachment for the better understanding


Attached Files Image(s)
   
Reply
#4
Not Solved
Hi venkatbatchu ,

After you click on the particular letter or <All>, as the data i.e. "7 Record displayed..." will display in the webTable, you can capture the dynamic value easly by use "GetCellData" method.

Let me know if you need any more info.
Thanks,
SUpputuri
Reply
#5
Not Solved
Hi ,

my issue is some what different now..

Now my code shows the 500 records in the msg box..but it always works out if the inout returns 500 records only,if i give a different search criteria..it says object not defined since it tries to return other number than 500 records..i realized, the regular expression needs to be there for my code.. but i am not sure how i can do that.

here is my code

Code:
Browser("MDC").Page("MDC").Frame("mdma_bottom").Link("POD").Click
'Browser("MDC").Page("MDC").Frame("mdma_bottom_2").WebEdit("ClassName:=WebEdit", "Name:=txtSearchCriteria").Set "geetha"
Browser("MDC").Page("MDC").Frame("mdma_bottom_2").WebEdit("txtSearchCriteria").Set "kim"
Browser("MDC").Page("MDC").Frame("mdma_bottom_2").WebButton("Search").Click
Browser("MDC").Page("MDC").Frame("mdma_bottom_2").WebList("ddlSearchType").Select "Customer Name"
Browser("MDC").Page("MDC").Frame("mdma_bottom_2").WebButton("Search").Click
Browser("MDC").Page("MDC").Sync

txtstr1 = Browser("MDC").Page("MDC").Frame("mdma_bottom_2").WebElement("pgrSdpSummary:Page:ddlPage").GetROProperty("innertext")
'WebElement("pgrSdpSummary:Page:ddlPage").Object.innerHTML

msgbox txtstr1


any help?
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  "UFT has stopped working" is displayed during running the script kotaramamohana 0 1,332 08-24-2018, 01:07 PM
Last Post: kotaramamohana
  array to be captured and displayed Anu209 0 1,249 06-24-2017, 10:19 AM
Last Post: Anu209
  Multiple 2 IE browsers are being displayed VA1405 1 1,881 01-15-2014, 07:20 AM
Last Post: basanth27
  Type mismatch is displayed for .SET method (Blank value) dineshb 4 4,331 07-20-2010, 08:58 PM
Last Post: dineshb

Forum Jump:


Users browsing this thread: 6 Guest(s)