SPONSORS:






User Tag List

Results 1 to 4 of 4
  1. #1
    Junior Member
    Join Date
    Jun 2000
    Location
    Center Harbor, NH USA
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Same window, different parents

    Hi all!
    I'm attempting to create a testframe for the PowerBuilder application that is being developed here and I've run into a bit of a problem with the declarations of messageboxes. All the messageboxes are declared with the same tags, but they each have different parents. Because of this I've declared a new window for each instance of the messagebox even though one would suffice.

    Is there any way that I can declare multiple parents? Or is there some other way I can get around creating a separate declaration for each of these identical windows?

    Thank you!

    Seth


  2. #2
    Senior Member
    Join Date
    Mar 2000
    Location
    Dublin, Ireland
    Posts
    152
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Same window, different parents

    Hi Seth,

    Use the "~ActiveApp/" tagging feature. For example if the caption on the message box is 'Error' then your declaration would look something like,

    window DialogBox MyMessageBox
    tag "~ActiveApp/Error"
    ...
    ...

    "~ActiveApp/..." specifies that the parent is the currently active window.

    Regards,

    John.
    John O'Neill.
    Quality Automation Ltd.
    www.quality-automation.com

  3. #3
    Senior Member
    Join Date
    Jun 2000
    Location
    Waltham, MA
    Posts
    107
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Same window, different parents

    Hi,

    There's actually an easy solution to this.
    First, you can delete all but one of the MessageBox declarations. Then, remove the parent from the MessageBox declaration. Then add "~ActiveApp/" to the beginning of the tag. So the declaration should look something like:

    DialogBox MessageBox
    tag "~ActiveApp/Message"

    The "~ActiveApp/" will basically tell the script to use the active window as the parent of the MessageBox.

  4. #4
    Junior Member
    Join Date
    Jun 2000
    Location
    Center Harbor, NH USA
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Same window, different parents

    That did the trick! Thanks for the help!

    Seth

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin 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 09:18 PM.

Copyright BetaSoft Inc.