Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

How to dynamically open a control on a userobject

7 posts in Objects Last posting was on 2002-09-06 15:13:59.0Z
Thomas Andersen Posted on 2002-08-29 18:02:04.0Z
Newsgroups: sybase.public.powerbuilder.objects
From: "Thomas Andersen" <tandersen@dsicdi.com>
Subject: How to dynamically open a control on a userobject
Date: Thu, 29 Aug 2002 14:02:04 -0400
Lines: 21
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: ip-pa-jtown-24-159-137-208.charterpa.com 24.159.137.208
Message-ID: <364_ZizPmf4TCHA.276@forums.sybase.com>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.powerbuilder.objects:989
Article PK: 713551

Hello,

I am having trouble dynamically creating and opening a statictext box on
another userobject. The OpenUserObject function only applies windows and
won't work on visual userobjects. Even when I do apply the function to the
parent window statictext control does not show up. I get no errors when
debugging. This is the code I have:

lst_event[li_loop] = create StaticText
parent.OpenUserObject(lst_event[li_loop],0,0)
lst_event[li_loop].BringToTop = true
lst_event[li_loop].y = <some number>
lst_event[li_loop].x = <some number>
lst_event[li_loop].height = <some number>

please advise.

thanks,
Thomas Andersen


Neil Rothschild Posted on 2002-08-29 18:48:45.0Z
Newsgroups: sybase.public.powerbuilder.objects
From: "Neil Rothschild" <nrothschild@nmctech.com>
Subject: Re: How to dynamically open a control on a userobject
Date: Thu, 29 Aug 2002 14:48:45 -0400
Lines: 31
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: pcp280455pcs.owngsm01.md.comcast.net 68.55.6.68
Message-ID: <364_KlFVK54TCHA.81@forums.sybase.com>
References: <364_ZizPmf4TCHA.276@forums.sybase.com>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.powerbuilder.objects:988
Article PK: 713552

Try putting it in debug and looking very carefully at the variables for the
new control. Compare to the variables of a control of the same class
(statictext). You might have forgotten to set something- maybe the width?

"Thomas Andersen" <tandersen@dsicdi.com> wrote in message
news:ZizPmf4TCHA.276@forums.sybase.com...
> Hello,
>
> I am having trouble dynamically creating and opening a statictext box on
> another userobject. The OpenUserObject function only applies windows and
> won't work on visual userobjects. Even when I do apply the function to
the
> parent window statictext control does not show up. I get no errors when
> debugging. This is the code I have:
>
> lst_event[li_loop] = create StaticText
> parent.OpenUserObject(lst_event[li_loop],0,0)
> lst_event[li_loop].BringToTop = true
> lst_event[li_loop].y = <some number>
> lst_event[li_loop].x = <some number>
> lst_event[li_loop].height = <some number>
>
> please advise.
>
> thanks,
> Thomas Andersen
>
>


Thomas Andersen Posted on 2002-08-29 19:29:43.0Z
Newsgroups: sybase.public.powerbuilder.objects
From: "Thomas Andersen" <tandersen@dsicdi.com>
Subject: Re: How to dynamically open a control on a userobject
Date: Thu, 29 Aug 2002 15:29:43 -0400
Lines: 52
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: ip-pa-jtown-24-159-137-208.charterpa.com 24.159.137.208
Message-ID: <364_sk0olQ5TCHA.276@forums.sybase.com>
References: <364_ZizPmf4TCHA.276@forums.sybase.com> <364_KlFVK54TCHA.81@forums.sybase.com>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.powerbuilder.objects:986
Article PK: 713548

The problem actually goes a little deeper than that. I need it to be opened
on the userobject and not on the main window, because I have several
userobjects layered on top of each other and like this the statictext boxes
will appear on top no matter which userobject is currently on top instead of
only when a certain object is on top. I do not have the option of tracking
this externally as I am developing a package for other programmers to simply
add to their apps without having to worry about what's going on. There's
also no guarantee that the other programmer even chose to display this
object in the first place making it even more important that the text boxes
are controlled on the userobject instead of on the main window.

thanks,
Thomas Andersen

"Neil Rothschild" <nrothschild@nmctech.com> wrote in message
news:KlFVK54TCHA.81@forums.sybase.com...
> Try putting it in debug and looking very carefully at the variables for
the
> new control. Compare to the variables of a control of the same class
> (statictext). You might have forgotten to set something- maybe the width?
>
>
> "Thomas Andersen" <tandersen@dsicdi.com> wrote in message
> news:ZizPmf4TCHA.276@forums.sybase.com...
> > Hello,
> >
> > I am having trouble dynamically creating and opening a statictext box on
> > another userobject. The OpenUserObject function only applies windows
and
> > won't work on visual userobjects. Even when I do apply the function to
> the
> > parent window statictext control does not show up. I get no errors when
> > debugging. This is the code I have:
> >
> > lst_event[li_loop] = create StaticText
> > parent.OpenUserObject(lst_event[li_loop],0,0)
> > lst_event[li_loop].BringToTop = true
> > lst_event[li_loop].y = <some number>
> > lst_event[li_loop].x = <some number>
> > lst_event[li_loop].height = <some number>
> >
> > please advise.
> >
> > thanks,
> > Thomas Andersen
> >
> >
>
>


Philip_Salgannik Posted on 2002-08-30 16:52:58.0Z
Newsgroups: sybase.public.powerbuilder.objects
From: Philip_Salgannik
Date: Fri, 30 Aug 2002 12:52:58 -0400
Subject: Re: How to dynamically open a control on a userobject
Lines: 7
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Message-ID: <364_ED5C9625044906FF005CBD7785256C25.006F2AAA85256C24@webforums>
References: <364_ZizPmf4TCHA.276@forums.sybase.com> <364_KlFVK54TCHA.81@forums.sybase.com> <364_sk0olQ5TCHA.276@forums.sybase.com>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com!webforums.sybase.com!news
Xref: forums-1-dub sybase.public.powerbuilder.objects:977
Article PK: 713539

This is actually a FAQ, search
http://groups.google.com/advanced_group_search

1) CREATE statictext will not work, you need to use OpenUserObject with
visual controls.

2) You can reparent your dynamically opened object to the userobject of
your choice with SetParent API...


Thomas Andersen Posted on 2002-09-06 15:13:59.0Z
Newsgroups: sybase.public.powerbuilder.objects
From: "Thomas Andersen" <tandersen@dsicdi.com>
Subject: Re: How to dynamically open a control on a userobject
Date: Fri, 6 Sep 2002 11:13:59 -0400
Lines: 17
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: ip-pa-jtown-24-159-137-208.charterpa.com 24.159.137.208
Message-ID: <364_l7EuBnbVCHA.285@forums.sybase.com>
References: <364_ZizPmf4TCHA.276@forums.sybase.com> <364_KlFVK54TCHA.81@forums.sybase.com> <364_sk0olQ5TCHA.276@forums.sybase.com> <364_ED5C9625044906FF005CBD7785256C25.006F2AAA85256C24@webforums>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.powerbuilder.objects:967
Article PK: 713532

Thanks guys, I appreciate you help.

Thomas Andersen

<Philip_Salgannik> wrote in message
news:ED5C9625044906FF005CBD7785256C25.006F2AAA85256C24@webforums...
> This is actually a FAQ, search
> http://groups.google.com/advanced_group_search
>
> 1) CREATE statictext will not work, you need to use OpenUserObject with
> visual controls.
>
> 2) You can reparent your dynamically opened object to the userobject of
> your choice with SetParent API...


Neil Rothschild Posted on 2002-08-30 20:49:51.0Z
Newsgroups: sybase.public.powerbuilder.objects
From: "Neil Rothschild" <nrothschild@nmctech.com>
Subject: Re: How to dynamically open a control on a userobject
Date: Fri, 30 Aug 2002 16:49:51 -0400
Lines: 15
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: pcp280455pcs.owngsm01.md.comcast.net 68.55.6.68
Message-ID: <364_2#OchhGUCHA.276@forums.sybase.com>
References: <364_ZizPmf4TCHA.276@forums.sybase.com> <364_KlFVK54TCHA.81@forums.sybase.com> <364_sk0olQ5TCHA.276@forums.sybase.com> <364_ED5C9625044906FF005CBD7785256C25.006F2AAA85256C24@webforums>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.powerbuilder.objects:976
Article PK: 713543

Thanks, Phillip, I learned something answering a question <s>

<Philip_Salgannik> wrote in message
news:ED5C9625044906FF005CBD7785256C25.006F2AAA85256C24@webforums...
> This is actually a FAQ, search
> http://groups.google.com/advanced_group_search
>
> 1) CREATE statictext will not work, you need to use OpenUserObject with
> visual controls.
>
> 2) You can reparent your dynamically opened object to the userobject of
> your choice with SetParent API...


Neil Rothschild Posted on 2002-08-29 21:11:56.0Z
Newsgroups: sybase.public.powerbuilder.objects
From: "Neil Rothschild" <nrothschild@nmctech.com>
Subject: Re: How to dynamically open a control on a userobject
Date: Thu, 29 Aug 2002 17:11:56 -0400
Lines: 80
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: pcp280455pcs.owngsm01.md.comcast.net 68.55.6.68
Message-ID: <364_d2fCLJ6TCHA.74@forums.sybase.com>
References: <364_ZizPmf4TCHA.276@forums.sybase.com> <364_KlFVK54TCHA.81@forums.sybase.com> <364_sk0olQ5TCHA.276@forums.sybase.com>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.powerbuilder.objects:985
Article PK: 713550

I wasn't trying to solve the world's problems- just one tiny problem <s>.

Can't help you with the main issue... given the emphaisis on oo
encapsulation with PB, it should let you do that. You should post this on
the futures group and put in a case express enhancement request. I'm sure
others have, but it never hurts to have your vote count.

If you search google for 'powerbuilder openuserobject userobject' or
something similar you might get some ideas for a work around, including
using a tab.

Neil

"Thomas Andersen" <tandersen@dsicdi.com> wrote in message
news:sk0olQ5TCHA.276@forums.sybase.com...
> The problem actually goes a little deeper than that. I need it to be
opened
> on the userobject and not on the main window, because I have several
> userobjects layered on top of each other and like this the statictext
boxes
> will appear on top no matter which userobject is currently on top instead
of
> only when a certain object is on top. I do not have the option of
tracking
> this externally as I am developing a package for other programmers to
simply
> add to their apps without having to worry about what's going on. There's
> also no guarantee that the other programmer even chose to display this
> object in the first place making it even more important that the text
boxes
> are controlled on the userobject instead of on the main window.
>
> thanks,
> Thomas Andersen
>
>
> "Neil Rothschild" <nrothschild@nmctech.com> wrote in message
> news:KlFVK54TCHA.81@forums.sybase.com...
> > Try putting it in debug and looking very carefully at the variables for
> the
> > new control. Compare to the variables of a control of the same class
> > (statictext). You might have forgotten to set something- maybe the
width?
> >
> >
> > "Thomas Andersen" <tandersen@dsicdi.com> wrote in message
> > news:ZizPmf4TCHA.276@forums.sybase.com...
> > > Hello,
> > >
> > > I am having trouble dynamically creating and opening a statictext box
on
> > > another userobject. The OpenUserObject function only applies windows
> and
> > > won't work on visual userobjects. Even when I do apply the function
to
> > the
> > > parent window statictext control does not show up. I get no errors
when
> > > debugging. This is the code I have:
> > >
> > > lst_event[li_loop] = create StaticText
> > > parent.OpenUserObject(lst_event[li_loop],0,0)
> > > lst_event[li_loop].BringToTop = true
> > > lst_event[li_loop].y = <some number>
> > > lst_event[li_loop].x = <some number>
> > > lst_event[li_loop].height = <some number>
> > >
> > > please advise.
> > >
> > > thanks,
> > > Thomas Andersen
> > >
> > >
> >
> >
>
>