• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

focus in textarea

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i'm using two screens,
in the second one i use one textarea.
when i press continue button in the first page the focus should be on that textarea.
its working nicely.
when i use the go back button in the second page,all the fields in the second page should be cleared and first page should come.
its also working nicely,
the problem is when i again press continue the second page is showed but the focus went somewhere.....
i dont know why,
and when i skip the clearing coding for the textarea i'm getting the focus...
so whats the problem with clearing the textfield???
anyone pls tell me the solution
 
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
> anyone pls tell me the solution

try adding this line at the end of your 'continue' method
[textArea].requestFocusInWindow();

if still not working, post a small sample program that demonstrates the problem
 
Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic