wood burning stoves 2.0*
The moose likes Struts and the fly likes set value in text box Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "set value in text box" Watch "set value in text box" New topic
Author

set value in text box

Kaustubh G Sharma
Ranch Hand

Joined: May 13, 2010
Posts: 1270

I am using html tags where in one text box i have to set the current date as a value if i search on it by default...

Date Picker code............






text box code..........



No Kaustubh No Fun, Know Kaustubh Know Fun..
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

What's the actual question?

In any case, why not just handle that via Struts and set the default value on the server side?
Kaustubh G Sharma
Ranch Hand

Joined: May 13, 2010
Posts: 1270

Actually I solved the problem david i just want to set current date in text box when I select no date from date picker and search well finally I did it by setting value in textbox property when it has no value...let me know if you have any other idea for it..
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60810
    
  65

Please be sure to ask Struts questions in the Struts forum. I have moved this post there for you.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

I *did* have another idea for it, which I told you: pre-populate on the server side.
Kaustubh G Sharma
Ranch Hand

Joined: May 13, 2010
Posts: 1270

No idea how to do it??
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

http://faq.javaranch.com/java/SelectDefaultValue

There's a couple hints in that part of the JavaRanch Struts 1 FAQ.
Kaustubh G Sharma
Ranch Hand

Joined: May 13, 2010
Posts: 1270

Thanks David
 
wood burning stoves
 
subject: set value in text box
 
Similar Threads
Using checkbox on Spring 2.5 MVC ?
selecting dynamically added rows of a table
How to update a image using servlet?
Element Shift Problem in Dynamic Form
Tooltip issue (Struts, Ajax, YUI/Yahoo User Interface, Javascript)