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 get tabpage! ?

7 posts in Objects Last posting was on 2004-06-11 16:43:37.0Z
Mike Posted on 2004-06-08 10:31:43.0Z
Reply-To: "Mike" <sc99sc@hotmail.com>
From: "Mike" <sc99sc@hotmail.com>
Newsgroups: sybase.public.powerbuilder.objects
Subject: how to get tabpage! ?
Lines: 35
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
X-Original-NNTP-Posting-Host: 61.11.108.106
Message-ID: <40c595e4@forums-2-dub>
X-Original-Trace: 8 Jun 2004 03:33:08 -0700, 61.11.108.106
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 8 Jun 2004 03:29:17 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 8 Jun 2004 03:31:43 -0700
X-Trace: forums-1-dub 1086690703 10.22.108.75 (8 Jun 2004 03:31:43 -0700)
X-Original-Trace: 8 Jun 2004 03:31:43 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.objects:7922
Article PK: 735194

Hello All ,

I am facing one problem , by below code i am getting tab! , but please tell
me how i can get tabpage ?

because on tabpage i am have so many controls like ( command button , text
etc.)



so please tell me , how I can get tabpage and how to get it's reference ?


// now go get text size information
choose case typeof(temp)
case commandbutton!
commandbutton cb
cb = temp
size_ctrl[i].fontsize = cb.textsize

case tab!
tab tb
tb = temp
size_ctrl[i].fontsize = tb.textsize
end choose

//


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004


Scott Morris Posted on 2004-06-08 12:29:49.0Z
From: "Scott Morris" <bogus@bogus.com>
Newsgroups: sybase.public.powerbuilder.objects
References: <40c595e4@forums-2-dub>
Subject: Re: how to get tabpage! ?
Lines: 43
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
X-Original-NNTP-Posting-Host: ip52-gadivinv-a8.atl1.exsbs.net
Message-ID: <40c5b194$1@forums-2-dub>
X-Original-Trace: 8 Jun 2004 05:31:16 -0700, ip52-gadivinv-a8.atl1.exsbs.net
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 8 Jun 2004 05:27:24 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 8 Jun 2004 05:29:49 -0700
X-Trace: forums-1-dub 1086697789 10.22.108.75 (8 Jun 2004 05:29:49 -0700)
X-Original-Trace: 8 Jun 2004 05:29:49 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.objects:7924
Article PK: 735193

A tab control has its own control array - just like a window. This control
array contains the pages. In turn, each page contains its own control
array. A perfect example of recursion.

"Mike" <sc99sc@hotmail.com> wrote in message news:40c595e4@forums-2-dub...
> Hello All ,
>
> I am facing one problem , by below code i am getting tab! , but please
tell
> me how i can get tabpage ?
>
> because on tabpage i am have so many controls like ( command button , text
> etc.)
>
>
>
> so please tell me , how I can get tabpage and how to get it's reference ?
>
>
> // now go get text size information
> choose case typeof(temp)
> case commandbutton!
> commandbutton cb
> cb = temp
> size_ctrl[i].fontsize = cb.textsize
>
> case tab!
> tab tb
> tb = temp
> size_ctrl[i].fontsize = tb.textsize
> end choose
>
> //
>
>
> ---
> Outgoing mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004
>
>


Mike Posted on 2004-06-09 10:03:34.0Z
Reply-To: "Mike" <sc99sc@hotmail.com>
From: "Mike" <sc99sc@hotmail.com>
Newsgroups: sybase.public.powerbuilder.objects
References: <40c595e4@forums-2-dub> <40c5b194$1@forums-2-dub>
Subject: Re: how to get tabpage! ?
Lines: 72
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 61.11.108.106
X-Original-NNTP-Posting-Host: 61.11.108.106
Message-ID: <40c6e076@forums-1-dub>
Date: 9 Jun 2004 03:03:34 -0700
X-Trace: forums-1-dub 1086775414 61.11.108.106 (9 Jun 2004 03:03:34 -0700)
X-Original-Trace: 9 Jun 2004 03:03:34 -0700, 61.11.108.106
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.objects:7928
Article PK: 735199

Hi ,

if possible then can you tell me any example ,
actully if how to store the variable in tabpage , because there is not
object type for tabpage

and on tabpage i inserted so many controls and i want to change there resize
property.

if you can tell me example then it will really very much helpfull.
Regards,
Mike

"Scott Morris" <bogus@bogus.com> wrote in message
news:40c5b194$1@forums-2-dub...
> A tab control has its own control array - just like a window. This
control
> array contains the pages. In turn, each page contains its own control
> array. A perfect example of recursion.
>
> "Mike" <sc99sc@hotmail.com> wrote in message news:40c595e4@forums-2-dub...
> > Hello All ,
> >
> > I am facing one problem , by below code i am getting tab! , but please
> tell
> > me how i can get tabpage ?
> >
> > because on tabpage i am have so many controls like ( command button ,
text
> > etc.)
> >
> >
> >
> > so please tell me , how I can get tabpage and how to get it's reference
?
> >
> >
> > // now go get text size information
> > choose case typeof(temp)
> > case commandbutton!
> > commandbutton cb
> > cb = temp
> > size_ctrl[i].fontsize = cb.textsize
> >
> > case tab!
> > tab tb
> > tb = temp
> > size_ctrl[i].fontsize = tb.textsize
> > end choose
> >
> > //
> >
> >
> > ---
> > Outgoing mail is certified Virus Free.
> > Checked by AVG anti-virus system (http://www.grisoft.com).
> > Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004
> >
> >
>
>

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004


Scott Morris Posted on 2004-06-09 12:56:19.0Z
From: "Scott Morris" <bogus@bogus.com>
Newsgroups: sybase.public.powerbuilder.objects
References: <40c595e4@forums-2-dub> <40c5b194$1@forums-2-dub> <40c6e076@forums-1-dub>
Subject: Re: how to get tabpage! ?
Lines: 79
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: ip52-gadivinv-a8.atl1.exsbs.net
X-Original-NNTP-Posting-Host: ip52-gadivinv-a8.atl1.exsbs.net
Message-ID: <40c708f3$1@forums-1-dub>
Date: 9 Jun 2004 05:56:19 -0700
X-Trace: forums-1-dub 1086785779 65.205.162.52 (9 Jun 2004 05:56:19 -0700)
X-Original-Trace: 9 Jun 2004 05:56:19 -0700, ip52-gadivinv-a8.atl1.exsbs.net
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.objects:7929
Article PK: 735201

<snip>
If you look at your exported source for the window you are using, you will
see that the tabpages added in the window painter are defined (by PB) as
user objects. I'm not certain as to what you are asking. At the bottom of
this message is an event that recursively traverses the objects in a window.
It is called from code within a window as follows:

PowerObject lpo_objs[ ]
int li_ret

li_ret = This.event ue_set_updateable_objects_sub (This.control, lpo_objs)
If li_ret = 1 Then
this.of_SetUpdateObjects(lpo_objs)
End If


event
ue_set_updateable_objects_sub;//////////////////////////////////////////////
////////////////////////////////
//
// Event: ue_set_updateable_objects_sub
//
// Arguments:
// apo_control Array of controls to check for accepttext
// apo_object Array of updateable controls (output)
//
// Returns: integer
// 1 = success, apo_object updated as needed
// -1 = error
//
// Description:
// Add any datastores or datawindows found in the control array to the
// the object array.
//
// Note:
// This function is called recursively to handle tab controls and user
objects.
////////////////////////////////////////////////////////////////////////////
//

int li_ret = 1
long ll_index
string ls_class
Powerobject lpo_tocheck
datawindow lu_dw
datastore ln_ds
UserObject luo_control
tab lu_tab

FOR ll_index = 1 TO upperbound(apo_control)
lpo_tocheck = apo_control[ll_index]
If IsNull(lpo_tocheck) Then continue
If Not IsValid(lpo_tocheck) Then continue

// Ignore dw_1 - not used
ls_class = lpo_tocheck.classname ()
If ls_class = "dw_1" Then continue

CHOOSE CASE TypeOf (lpo_tocheck)
CASE Userobject!
luo_control = lpo_tocheck
li_ret = This.event ue_set_updateable_objects_sub (luo_control.control,
apo_object)
CASE Tab!
lu_tab = lpo_tocheck
li_ret = This.event ue_set_updateable_objects_sub (lu_tab.control,
apo_object)
CASE DataWindow!
lu_dw = lpo_tocheck
apo_object[upperbound (apo_object) + 1] = lu_dw
CASE DataStore!
ln_ds = lpo_tocheck
apo_object[upperbound (apo_object) + 1] = ln_ds
END CHOOSE
NEXT

return li_ret


Bob Francis Posted on 2004-06-09 14:29:08.0Z
From: "Bob Francis" <bob.francis@stld.com>
Newsgroups: sybase.public.powerbuilder.objects
References: <40c595e4@forums-2-dub>
Subject: Re: how to get tabpage! ?
Lines: 47
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
X-Original-NNTP-Posting-Host: 208.44.233.2
Message-ID: <40c71f0d@forums-2-dub>
X-Original-Trace: 9 Jun 2004 07:30:37 -0700, 208.44.233.2
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 9 Jun 2004 07:26:34 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 9 Jun 2004 07:29:08 -0700
X-Trace: forums-1-dub 1086791348 10.22.108.75 (9 Jun 2004 07:29:08 -0700)
X-Original-Trace: 9 Jun 2004 07:29:08 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.objects:7931
Article PK: 735204

Mike,
I have taken the sample resize code that is on codexchange and enhanced it
to handle tab objects. I must shamefully admit that I have used code from
codexchange, but up until now have not requested the ability to upload
anything. I put in the request to be a contributor and will upload the code
as soon as "they" let me.
Bob

"Mike" <sc99sc@hotmail.com> wrote in message news:40c595e4@forums-2-dub...
> Hello All ,
>
> I am facing one problem , by below code i am getting tab! , but please
tell
> me how i can get tabpage ?
>
> because on tabpage i am have so many controls like ( command button , text
> etc.)
>
>
>
> so please tell me , how I can get tabpage and how to get it's reference ?
>
>
> // now go get text size information
> choose case typeof(temp)
> case commandbutton!
> commandbutton cb
> cb = temp
> size_ctrl[i].fontsize = cb.textsize
>
> case tab!
> tab tb
> tb = temp
> size_ctrl[i].fontsize = tb.textsize
> end choose
>
> //
>
>
> ---
> Outgoing mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004
>
>


Bob Francis Posted on 2004-06-09 14:49:42.0Z
From: "Bob Francis" <bob.francis@stld.com>
Newsgroups: sybase.public.powerbuilder.objects
References: <40c595e4@forums-2-dub> <40c71f0d@forums-2-dub>
Subject: Re: how to get tabpage! ?
Lines: 100
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
X-Original-NNTP-Posting-Host: 208.44.233.2
Message-ID: <40c723d0$1@forums-2-dub>
X-Original-Trace: 9 Jun 2004 07:50:56 -0700, 208.44.233.2
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 9 Jun 2004 07:47:10 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 9 Jun 2004 07:49:42 -0700
X-Trace: forums-1-dub 1086792582 10.22.108.75 (9 Jun 2004 07:49:42 -0700)
X-Original-Trace: 9 Jun 2004 07:49:42 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.objects:7932
Article PK: 735203

Actually I guess you don't need the whole resize object for what you are
looking to do. Here is a chunk of code that you can use. Create a function
that takes a parameter called aw_window of type window and the following
code will serve as an example
////////////////////////////////////////////////////////
integer li_i, li_j, li_k
int li_tabpageCount
int li_controlCount

io_Control = aw_window.control

for li_i=1 to upperbound(io_Control)

choose case io_Control[li_i].typeof()

// lots of types of objects left out for this example so we can get to the
tab page!!

case tab!
tab ltb
ltb=create tab
ltb=io_Control[li_i]
ltb.tag="I'm modifying the tag"
// for tabs we are going to walk through the tab hierarchy
// to make sure we have all the visual elements in our control
// array.
li_tabpageCount = Upperbound(ltb.Control[])
For li_j = 1 to li_tabpageCount
li_controlCount = Upperbound(ltb.Control[li_j].control[])
for li_k =1 To li_controlCount
io_Control[Upperbound(io_Control) +1] =
ltb.Control[li_j].control[li_k]
choose case ltb.Control[li_j].control[li_k].typeof()
case Datawindow!
Datawindow ldwt
ldwt=create datawindow
ldwt= ltb.Control[li_j].control[li_k]
ldwt.tag="I'm modifying this tag also"
end choose
Next
Next
end choose
next
////////////////////////////////////////////////////////

"Bob Francis" <bob.francis@stld.com> wrote in message
news:40c71f0d@forums-2-dub...
> Mike,
> I have taken the sample resize code that is on codexchange and enhanced it
> to handle tab objects. I must shamefully admit that I have used code from
> codexchange, but up until now have not requested the ability to upload
> anything. I put in the request to be a contributor and will upload the
code
> as soon as "they" let me.
> Bob
>
> "Mike" <sc99sc@hotmail.com> wrote in message news:40c595e4@forums-2-dub...
> > Hello All ,
> >
> > I am facing one problem , by below code i am getting tab! , but please
> tell
> > me how i can get tabpage ?
> >
> > because on tabpage i am have so many controls like ( command button ,
text
> > etc.)
> >
> >
> >
> > so please tell me , how I can get tabpage and how to get it's reference
?
> >
> >
> > // now go get text size information
> > choose case typeof(temp)
> > case commandbutton!
> > commandbutton cb
> > cb = temp
> > size_ctrl[i].fontsize = cb.textsize
> >
> > case tab!
> > tab tb
> > tb = temp
> > size_ctrl[i].fontsize = tb.textsize
> > end choose
> >
> > //
> >
> >
> > ---
> > Outgoing mail is certified Virus Free.
> > Checked by AVG anti-virus system (http://www.grisoft.com).
> > Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004
> >
> >
>
>


Christos Ioannou Posted on 2004-06-11 16:43:37.0Z
From: Christos Ioannou <chriss@mymail.com>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7) Gecko/20040514
X-Accept-Language: en-us, en
MIME-Version: 1.0
Newsgroups: sybase.public.powerbuilder.objects
Subject: Re: how to get tabpage! ?
References: <40c595e4@forums-2-dub>
In-Reply-To: <40c595e4@forums-2-dub>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 194.125.252.20
X-Original-NNTP-Posting-Host: 194.125.252.20
Message-ID: <40c9e139$1@forums-1-dub>
Date: 11 Jun 2004 09:43:37 -0700
X-Trace: forums-1-dub 1086972217 194.125.252.20 (11 Jun 2004 09:43:37 -0700)
X-Original-Trace: 11 Jun 2004 09:43:37 -0700, 194.125.252.20
Lines: 36
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.objects:7940
Article PK: 735212

Hope this helps


------------------------------------------
WF_GET_ALL_CHILDREN(PowerObject ap_obj)
------------------------------------------

choose case ap_obj.typeof()

case Tab!
tab tpbo
tpbo = ap_obj
for k = 1 to upperbound(tpbo.control)
subobj[k] = f_classname(tpbo.control[k])
wf_get_all_children(tpbo.control[k])
next
end choose
-------------------------------------------

-------------------------------------------
f_classname(PowerObject a_obj)
-------------------------------------------
string name
powerobject obj

obj = a_obj.getparent()

do while isvalid(obj)
name = obj.classname() + '.' + name
obj = obj.getparent()
loop

name = name + a_obj.classname()

return name
--------------------------------------------