SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 5 of 5
  1. #1
    Junior Member
    Join Date
    Jun 2003
    Posts
    27
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    How to determine if an object is visible/invisible?

    I need to verify if an image object(Html.IMG) is visible/hidden on a page.

    Background:
    1) I know its ".id" property and so I searched the page dynamically and could get a handle to the image object(invisible to the human eye).
    2) I tried searching through all its active properties to find a property which will tell me that the object is actually invisible to the human eye....but could not find one.
    3) I tried using the "isShowing()" API...but it returned "true" inspite of the fact that the image was invisible.


    Question: Does somebody know how to determine if an object is visible to the human eye(or not)?

    Thanks in advance.

  2. #2
    Member
    Join Date
    Oct 2001
    Location
    New York, NY
    Posts
    44
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to determine if an object is visible/invisible?

    My approach in such situations: create a properties VP when the object not visible and play back when the object is visible. Look at the properties that fail in the VP and work from there.

  3. #3
    Member
    Join Date
    Mar 2003
    Location
    Ottawa, Ontario, Canada
    Posts
    94
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to determine if an object is visible/invisible?

    Hi,

    When I am looking at the properties of an object before adding them to my virtual object map, I do the following (in a function that receives an object):

    TestObject {} testobjects = passedObject.getMappableChildren();

    I then look at several of the object's properties, namely:
    .name
    .class
    .text
    .title
    .tag
    using the function
    myProperty = (String)testObject.getProperty(".name");
    or ".class" or ".text",...

    When there are hidden objects on my screen, the ".class" property will usually come out to something similar to this:
    Html.INPUT.hidden

    Then again, I only seem to have hidden edit fields on my forms at the present time. No images.

    I hope that this helps a bit anyway.

    André

  4. #4
    Member
    Join Date
    Mar 2003
    Location
    Ottawa, Ontario, Canada
    Posts
    94
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to determine if an object is visible/invisible?

    Opps! Made a little mistake. One of the top lines should have been:
    TestObject [] testobjects = passedObject.getMappableChildren();

  5. #5
    Member
    Join Date
    Jun 2003
    Location
    Bangalore
    Posts
    40
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to determine if an object is visible/invisible?

    Use this...it works a lot better

    targetObject.isPointInObject(targetObject.getScree nPoint());

    If .exists returns TRUE and still its not enabled, this may work by returning FALSE.

    What it does...it sees if the required object is visible ON SCREEN!!!
    Many times object exists but is not visible( div tags messages) and in those times this would work.

    Let me know if this was useful

    keshav

 

 

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 10.00%
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 02:17 PM.

Copyright BetaSoft Inc.