Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Help with choice group..

 
Charline Louis
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,

i want to ask about choice group and textfield..
there's a choicegroup(POPUP) and textfield (UNEDITABLE)..
the thing is, that if the first option is chosen, the textbox next to it, it's uneditable, but with the other options, the textbox can be written..
is it possible??

help me, please..
Thanks..
 
Sukitha R Udugamasooriya
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try to implement the StateListener interface. It can listen to State Changes.
 
Charline Louis
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks Sukitha for your reply..
you were right, i must used itemStateChanged..
now, i wonder if i choose "Other" from choicegroup, the textfield will appear, and if i choose "A" the textfield will disappear..
is it possible ??

Thanks
 
Sukitha R Udugamasooriya
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Charline Louis,

Yes, its possible.
Call to append() or delete() in the Form where it is necessary in the stateChanged().

good luck
 
Charline Louis
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks for reply..
looks like you are misunderstanding..
i mean textfield, not text inside textfield..
or maybe i shoud write "textbox"..

Thanks
 
Sukitha R Udugamasooriya
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,

Actually I'm not. If you need to add an Item to a Form you have to call append() and if you want to delete an item from the Form call delete(). That will fulfill your requirement. I was not talking about formatting the text in the TextField.

regards
 
Charline Louis
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your reply..
i already solved it..
 
Charline Louis
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the problem now is, i want to setFocus on a textfield..
does anybody know any way to do the setFocus ??
help, please..

Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic