SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 7 of 7
  1. #1
    Junior Member
    Join Date
    Oct 2001
    Location
    Austin,TX
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    How do I capture object Data from a dynamic web page

    Can anybody help me to capture object data from a dynamic page?


    ------------------
    AR
    AR

  2. #2
    Senior Member
    Join Date
    Jan 2002
    Posts
    120
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How do I capture object Data from a dynamic web page

    So, in general, you can do the following. Use SQAGetProperty command to get the certain property of certain object. To get the list of objects you can use SQAGetChildren. It is a bit tricky with Web applications, so if you need more comments on how to use SQAGetChildren - let me know.
    SQAGetProperty gets one property value for one object. So, you have to identify the object you're looking for. In dynamic pages it is good idea to have unique IDs for this purpose, so that you could have:

    Result = SQAGetProperty("Type=HTMLTable;HTMLId=RegTable", "innerHTML", innerHTML)

    In this line table I'm searching for has ID="RegTable". Object type and ID (if one is available) you can get with Inspector (Tools/ Inspector menu item). Inspector shows how Robot identifies this object. You should use the same identification. I.e. if the first line of what Inspector shows for link is:
    HTMLLink,HTMLText=next;Index=2
    it means, that the only to unquely identify your link in SQAGetProperty is:

    Result = SQAGetProperty("Type=HTMLink;HTMLText=next;Index=2 ", "innerHTML", innerHTML)

    Now innerHTML variable contains value of innerHTML property for this link.

    ------------------

  3. #3
    Junior Member
    Join Date
    Oct 2001
    Location
    Austin,TX
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How do I capture object Data from a dynamic web page

    SQAGetProperty() is only to take the value of object property. I want to take the link for its data. For instance, table heading name,address,state etc. etc. When I want a pick up any address link, I couldn't do that. I think so far I know, there is a Object Data command comes with Robot 2001/2002 to serve this problem.

    ------------------
    AR
    AR

  4. #4
    Senior Member
    Join Date
    Jan 2002
    Posts
    120
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How do I capture object Data from a dynamic web page

    I don't get the idea. What is "link" for object data? I'm using 2001.03.00. I can get HTML text of any object and any page with Inspector. So, if you want smth, what can be found in HTML source of this page, you can get anything. But more than in HTML - no, you can't.

    ------------------

  5. #5
    Junior Member
    Join Date
    Oct 2001
    Location
    Austin,TX
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How do I capture object Data from a dynamic web page

    There is a Link on cell of the table. But it is dynamically changed always. Suppose, the table header name 'address'. Under the address every row has a link on cell. I want to capture this text so that it can click on the cell in stead of text when it play back.

    Yes I can see using the Inspector but how can I put this HTMLlink text and put it to a variable and call from there. That was my question.

    AR

  6. #6
    Senior Member
    Join Date
    Jan 2002
    Posts
    120
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How do I capture object Data from a dynamic web page

    Frankly speaking. I'm having the same problem right now. Solutions which I see for myself are: 1. Have unique ID for each link; 2. Parse HTML text of the whole document/ table.

    For 1:
    If your programmer gives you unique IDs created like "address_" + ID of this record in database, you're having perfect way how to select properties of this certain object: you just know that first address link on your page has HTMLId=address_1, the second - address_2, etc.

    For 2:
    That's worse. That's my case. I'm storing in variable HTML text for the whole table. Then parse it: the first <TR> tag is table header. The second <TR> is the first line with information. The second <TD> in this line is address field. So, I just get the text between second pair of <TD> </TD>. In this case just table must be uniquely identified.

    ------------------

  7. #7
    Senior Member
    Join Date
    Jan 2002
    Posts
    120
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How do I capture object Data from a dynamic web page

    Hm, sorry for problems - it's because my answer contains HTML tags. Will try once more.
    So, the lost text is (I place tag names in quotations):


    "TR" tag is table header. The second "TR" is the first line with information. The second (third, forth...) "TD" in this line is address field. So, I just get the text between second pair of "TD" "/TD" - that's HTML text for link which is there.


    ------------------

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 11.54%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 10:48 PM.

Copyright BetaSoft Inc.