Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Button click on the pop up should click button on another page

 
veda Cherak
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,
I have a page1 with TextField,ComboBox and hidden button.
When I try to enter values in TextField it opens a new pop up(page 2) with few options and enter button. Then when I click enter button I want to click the hidden button on the page 1.
How can I achieve this ?
My basic idea is to populate the ComboBox when I click the Enter Button on page 2.

Please suggest.

 
Paul Clapham
Sheriff
Posts: 21107
32
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
veda it wrote:My basic idea is to populate the ComboBox when I click the Enter Button on page 2.


Then just do it. Write code which does it and execute that code. I don't see why you need weird stuff like clicking hidden buttons.
 
veda Cherak
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes I don't really need a hidden button but it was my option.
As the ComboBox and EnterButton are on two different pages and I didn't know a way to populate it on EnterButton click.

I have all my logic on HiddenButton which retrieves data from the DB and populates the ComboBox working right now. So I though if I can invoke this button click from
the other Page EnterButton my problem will be solved.

Please let me know if there is a better way.



 
Ranganathan Kaliyur Mannar
Bartender
Posts: 1101
10
Java Netbeans IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Then move all the logic of the HiddenButton into a separate 'public' method(you can continue to invoke this from the actionListener of that button if you need). Then, call this method from the popup...
 
veda Cherak
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ranganathan Kaliyur Mannar wrote:Then move all the logic of the HiddenButton into a separate 'public' method(you can continue to invoke this from the actionListener of that button if you need). Then, call this method from the popup...


Thanks you Ranga. I tried a different way to enable this button but the solution you gave is much better so will implement it .
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic