Subclass method -distorted now put again

June somewhere at
Wed May 7 04:55:09 PDT 2008

Ary Borenszweig Wrote:

> June escribió:
> > dwt.widget.Text has method
> >  
> > void setText  (char[] string); 
> > Sets the contents of the receiver to the given string.
> > 
> > In my application I use many of these text boxes each with a name so I need a function 
> > 
> > void setText(char[] name, char[] text){
> >    name.setText(text);}
> name.setText(text) ?
> But name is of type char[]
> > 
> > How can  I bring this into my program ?
> Maybe you could show what you do now, and how you would like to have it 
> if you were able to do what you want. I don't understand what you are 
> trying to do. :(

In a class 'Room'
I make a text box called  "speaker', and another called 'radio' etc
Text speaker = new Text;

all blank atm

In another module  'town' I create instance of 'room' and 
now I want to set the text in each

So Text class has  method  'setText(char[])

In 'town' I want to make another method like 

different parameters to setText () in Text- I need to find out how to do it please?

More information about the Digitalmars-d-learn mailing list