Question on Control Array or Control[]

I have some question about the Control Array or Control[]

Does anyone nowhere I can fine out how it is defined ? 
ie its structure.

I am using the control array to get all of the controls from a window
and changing each control's  text to French or English depending on a
variable. The function call  is fired on the open event of each
window. This is simple enough.

My problem is a Control of type DataWindow.

I what to change the statictext fields to French or English, but don't
know to access them genertically from the Control Array.

If control[x].typeof() = DataWindow! Then

   I want to get a new list off all controls on the DataWindow Control
   (statictext fields in this case)   and change their text fields.

end if

Thank You
Vic Douse

0
dousvic
10/15/1997 6:19:38 PM
sybase.powerbuilder.general 62418 articles. 19 followers. Follow

2 Replies
665 Views

Similar Articles

[PageSpeed] 42
Get it on Google Play
Get it on Apple App Store

The control array will contain a reference to the Datawindow contol and not
the Datawindow object.  You'll need to get a reference to the control (as
you currently do) and then loop though the visible objects, get their type,
make sure that those you want to change are of type "text", and change their
"text" property.

Regards,

Costas Tsaklas[Team Powersoft]
Elevated Technologies, Inc.
www.elevatedtech.com

Vic Douse wrote in message <344507fc.27232640@forums.powersoft.com>...
>
>I have some question about the Control Array or Control[]
>
>Does anyone nowhere I can fine out how it is defined ?
>ie its structure.
>
>I am using the control array to get all of the controls from a window
>and changing each control's  text to French or English depending on a
>variable. The function call  is fired on the open event of each
>window. This is simple enough.
>
>My problem is a Control of type DataWindow.
>
>I what to change the statictext fields to French or English, but don't
>know to access them genertically from the Control Array.
>
>If control[x].typeof() = DataWindow! Then
>
>   I want to get a new list off all controls on the DataWindow Control
>   (statictext fields in this case)   and change their text fields.
>
>end if
>
>Thank You
>Vic Douse
>


0
Costas
10/15/1997 6:41:18 PM
Vic Douse wrote:
> 
> I have some question about the Control Array or Control[]
> 
> Does anyone nowhere I can fine out how it is defined ?
> ie its structure.
> 
> I am using the control array to get all of the controls from a window
> and changing each control's  text to French or English depending on a
> variable. The function call  is fired on the open event of each
> window. This is simple enough.
> 
> My problem is a Control of type DataWindow.
> 
> I what to change the statictext fields to French or English, but don't
> know to access them genertically from the Control Array.
> 
> If control[x].typeof() = DataWindow! Then
> 
>    I want to get a new list off all controls on the DataWindow Control
>    (statictext fields in this case)   and change their text fields.
> 
> end if
> 
> Thank You
> Vic Douse
Vic,

You need to use describe() and modify() to accomplish the change of text
in dw.

-- 
Lijun

==============================================
Lijun Yang mailto: Yangl@sprintmail.com
	   mailto: Lyang@buster.rgti.com
BDM International, Inc.  http://www.bdm.com/
==============================================
0
Lijun
10/16/1997 1:33:15 AM
Reply: