Validate Button to run doCheck method of other fields

13 views
Skip to first unread message

James Richard

unread,
Feb 6, 2015, 3:56:10 PM2/6/15
to jenkin...@googlegroups.com
Hello,

I was wondering if there was a way to run other doCheck methods when the method for a ValidateButton finishes? 

  For example, say I have a textbox with a file name and it's doCheck method looks to see if the file exists.  If the file doesnt exist the User can press on the validate button to create the file and it returns a message saying that it was created.  The error message on the textbox still hangs around though.  Is there a way to run the doCheck method of the textbox after the file is created?

Any help is appreciated
Message has been deleted

James Richard

unread,
Feb 6, 2015, 5:29:59 PM2/6/15
to jenkin...@googlegroups.com

I found that there is a way to invoke the check methods using the Stapler :


Stapler.getCurrent().invoke(Stapler.getCurrentRequest(), Stapler.getCurrentResponse(), this, "/checkField");


The only problem is that the FormValidation messages appear next to the button not where the TextBox messages appear.

Any idea of how to get a Stapler for a specific field?
Reply all
Reply to author
Forward
0 new messages