Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Childobject weird behavior
#1
Not Solved
Using childobjects on a web page, I have run into an issue.

I have a datagrid with 1 to 100's of rows with a link in the first column. This link is an ID field, so use DP to search the childobjects for HTML TAG = A, Text = IDNumber. This works perfectly until I return more than about 100 records, at that point DP is unable to find the requested object but there is not an error generated. It just ends execution. I am thinking it's an overflow of some type. Is there a limit to using childobjects or something?

Thoughts?
Reply
#2
Not Solved
Can you paste your lines of statements?

Reply
#3
Not Solved
Code:
Set cobj = Description.Create()
cobj("text").value = "123456"
cobj("html tag").value = "a|A"
With  Browser(Browserobj).Page(Pageobj)
    set linkarray = .ChildObjects(cobj)   '<===this is the last line executed
    msgbox linkarray.Count   '<=== this returns an error "Object not found"
End with

This code works perfectly with 10 results, just not with 100.
Reply
#4
Not Solved
This issue turns out to not be an issue at all. It is instead poor development and human error. This issue is caused by the Page object changing, which is the poor development part...why have 2 different pages for the same search results?!?!....then the human error part...I didn't notice the page changed and had not compensated for it in the DP used to get the page object.

The only issue I have now is how slow the DP search gets when I have more objects to deal with. I would expect some, but this can border on unusable since the developers don't use pagination.

I really appreciate the response Saket.
Reply
#5
Not Solved
Not sure what jsknight tries to say here, may be he was replying to some other thread and by mistake it posted here.

regarding your query-I dont see any overflow issue. the problem I felt with the code is when you describing the cobj you have not mentioned class for that
can you try putting the class value as well and see how it goes.

Reply
#6
Not Solved
What I tried to say in my last post was that the code was not identifying the object because my browser page had changed and the DP I used to set the page was not correct.

However, now that my page is properly identified, and the link object is now found by using DP, the click event does not happen.

Adding the micclass did not help.

I am unsure what to try next. The link click code works if there are just a few results. More than 100, the object is found, but click does not occur and again, no error to troubleshoot.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Drag and Drop Annoying QTP Behavior ShaneP 1 4,522 08-21-2015, 07:25 PM
Last Post: Nj_Acc
  Childobject return wrong checkbox count.. VpnQTP 1 2,555 04-09-2015, 09:07 PM
Last Post: babu123
  QTP childObject hadar 1 2,845 04-23-2014, 05:00 AM
Last Post: kgovadav
  Unexpected Behavior of Reporter.Reportevent chinmaya chirasundara nayak 3 3,451 12-03-2013, 10:43 AM
Last Post: kotaramamohana
  QTP vbscript ArrayList strange behavior frankhovin 2 2,830 11-11-2013, 07:12 PM
Last Post: Parke

Forum Jump:


Users browsing this thread: 1 Guest(s)