Re: Struts 2 manually call a custom validation in an action

2015-05-05 Thread Christoph Nenning
> Please see: http://stackoverflow.com/questions/29603916/struts-2- > manually-call-a-custom-validation-in-an-action ~Regards, > ~~Alireza Fattahi > From: Alireza Fattahi > To: Struts Mailing List > Sent: Monday, 13 April 2015, 16:40 > Subject: Struts 2 m

Re: Struts 2 manually call a custom validation in an action

2015-04-14 Thread Alireza Fattahi
Please see: http://stackoverflow.com/questions/29603916/struts-2-manually-call-a-custom-validation-in-an-action  ~Regards, ~~Alireza Fattahi From: Alireza Fattahi To: Struts Mailing List Sent: Monday, 13 April 2015, 16:40 Subject: Struts 2 manually call a custom validation in an

Struts 2 manually call a custom validation in an action

2015-04-13 Thread Alireza Fattahi
We have used struts 2 validation with lots of custom validation to validate our forms.     @Validations(     customValidators =     { @CustomValidator(type = "AccountFormat", fieldName = "accountNo") }     ) Also we can can manually validate a fo

Re: Custom validation interceptor

2009-06-20 Thread Peter Bliznak
Preciously!..what you said about changing form is exactly what I was thinking. From: Dave Newton To: Struts Users Mailing List Sent: Saturday, June 20, 2009 8:35:50 PM Subject: Re: Custom validation interceptor Peter Bliznak wrote: > It is across entire

Re: Custom validation interceptor

2009-06-20 Thread Dave Newton
Peter Bliznak wrote: It is across entire app (there are many dozen of actions) - every single action has to have same behavior - 3 crosses go and try again. It's app for changing personal info on government issued documents - sorta wizard like thing. I can see how I can do it by keeping eye of p

Re: Custom validation interceptor

2009-06-20 Thread Peter Bliznak
t: Re: Custom validation interceptor Peter Bliznak wrote: > I have following requirement: If validation of the page fails 3 times > in row - invalidate session and redirect to index page. Should I > replace default validation interceptor in default stack with my own > to achieve what I am a

Re: Custom validation interceptor

2009-06-20 Thread Dave Newton
Peter Bliznak wrote: I have following requirement: If validation of the page fails 3 times in row - invalidate session and redirect to index page. Should I replace default validation interceptor in default stack with my own to achieve what I am after? I there any other way? Is this across the e

Re: Custom validation interceptor

2009-06-20 Thread Wes Wannemacher
I don't think a custom interceptor is required. You could probably get this done through hidden parameters or by storing attempts in the session or something. Do you have this req for one action or all actions in the app? On 6/20/09, Peter Bliznak wrote: > Hi, > I have following requirement: > If

Custom validation interceptor

2009-06-20 Thread Peter Bliznak
Hi,I have following requirement:If validation of the page fails 3 times in row - invalidate session and redirect to index page.Should I replace default validation interceptor in default stack with my own to achieve what I am after?I there any other way?Any hint would be greatly appreciatedPeter.

RE: Struts2: Custom Validation, message from property file

2008-10-21 Thread sean . chen
Hi all: We are planning to develop a new project on Websphere 5.x (Servlet 2.3/JSP 1.2/ JDK 1.4) and wonder if struts2 could work with these components? Thanks in advance sean - To unsubscribe, e-mail: [EMAIL PROTECTED] For a

Re: Struts2: Custom Validation, message from property file

2008-10-21 Thread Paweł Wielgus
hod inside Your action. >> Your action needs to extend ActionSupport. >> >> Best greetings, >> Paweł Wielgus. >> >> >> 2008/10/20 lbastil <[EMAIL PROTECTED]>: >>> >>> I have to use Custom Validation and set field errors like: >>

Re: Struts2: Custom Validation, message from property file

2008-10-21 Thread lbastil
bastil, > try getText() method inside Your action. > Your action needs to extend ActionSupport. > > Best greetings, > Paweł Wielgus. > > > 2008/10/20 lbastil <[EMAIL PROTECTED]>: >> >> I have to use Custom Validation and set field errors like: >> add

Re: Struts2: Custom Validation, message from property file

2008-10-20 Thread Paweł Wielgus
Hi Ibastil, try getText() method inside Your action. Your action needs to extend ActionSupport. Best greetings, Paweł Wielgus. 2008/10/20 lbastil <[EMAIL PROTECTED]>: > > I have to use Custom Validation and set field errors like: > addFieldError("", " > instea

Struts2: Custom Validation, message from property file

2008-10-20 Thread lbastil
I have to use Custom Validation and set field errors like: addFieldError("", "http://www.nabble.com/Struts2%3A-Custom-Validation%2C-message-from-property-file-tp20068036p20068036.html Sent from the Struts - User mailing list archiv

Re: Custom validation with Struts2

2008-09-10 Thread Dave Newton
; > >   > > label="%{getText('card_add_edit_field')}"> > > > >   value="%{EmpNo}"> > > > >   value="%{true}"> > > > >   value="%{true}"> > > > >   value="%{getText('button_submit

Re: Custom validation with Struts2

2008-09-10 Thread Priyanka.dandekar
mp.length() > 0) { > >     int tmpInt = Integer.parseInt(tmp); > >     this.setCardNo(tmpInt); > >         System.out.println("Card no (validation) = " + > cardNo); > >     if

Struts Custom Validation Question

2008-07-22 Thread Chandramouli P
. What my question is, when we select the first radio button and fills/clears the values and submitting the form only a set of validations to be performed and in the case of second radio button also we are doing the same thing. How can I implement a custom validation for this scenario? And also

Re: Action method specific custom validation

2008-07-09 Thread ManiKanta G
Thanks... I'll try right away... Regards, ManiKanta Gabriel Belingueres wrote: Yes. To form the validation method name just concatenate "validate" with your action's method name. 2008/7/9 ManiKanta G <[EMAIL PROTECTED]>: Hi, I've three execute() kind of methods in single action. To valid

Re: Action method specific custom validation

2008-07-09 Thread Gabriel Belingueres
Yes. To form the validation method name just concatenate "validate" with your action's method name. 2008/7/9 ManiKanta G <[EMAIL PROTECTED]>: > Hi, > > I've three execute() kind of methods in single action. > > To validate the data, we can use actionName-actionAliasName-validation.xml > for valida

Action method specific custom validation

2008-07-09 Thread ManiKanta G
Hi, I've three execute() kind of methods in single action. To validate the data, we can use actionName-actionAliasName-validation.xml for validating actionName specific validations. But how to write custom validate() to deal specifically based on the method being requested. Is there are pro

Re: Custom validation with Struts2

2008-03-18 Thread Laurie Harper
Lukasz Lenart wrote: I'm not sure were is the problem but I've just checked such simple example below and everything is ok. Maybe you should consider to use Long instead of Integer, because when you enter more then 2147483647 to the field you will get some strange value back to the input (because

Re: Custom validation with Struts2

2008-03-18 Thread Lukasz Lenart
I'm not sure were is the problem but I've just checked such simple example below and everything is ok. Maybe you should consider to use Long instead of Integer, because when you enter more then 2147483647 to the field you will get some strange value back to the input (because you loose precision ;-

RE: Custom validation with Struts2

2008-03-18 Thread Filippov, Andrey
return response; } public void setResponse(HttpServletResponse response) { this.response = response; } public int getFieldName() { return fieldName; } public void setFieldName(int fieldName) {

Re: Custom validation with Struts2

2008-03-18 Thread Lukasz Lenart
> request = ServletActionContext.getRequest(); > String tmp = ""; > try { >tmp = request.getParameter("cardNo"); >Integer i = this.getCardNo(); >if (tmp != null && tmp.length() > 0) { >

Custom validation with Struts2

2008-03-18 Thread Filippov, Andrey
Hello everybody, I need to validate only 1 field on the jsp. It value should be between 1 and 99. Initially I started to implement through int validation but it seemed to go wrong - it works with some limitation - maximum value should not exceed 1000 or something like that. I am trying t

Fwd: Struts 2 Custom Validation

2008-02-27 Thread Dave Newton
I've forwarded this to the struts-user list; it's better to ask questions there. --- Thaminda Karunanayake <[EMAIL PROTECTED]> wrote: > From: "Thaminda Karunanayake" <[EMAIL PROTECTED]> > I'm using Struts 2 client side validation to validate a password > confirmation field. > But to do that I can'

Re: Struts 2 Custom Validation

2008-02-27 Thread Randy Burgess
Struts Users Mailing List > Date: Wed, 27 Feb 2008 09:48:57 -0500 > To: Struts Users Mailing List > Subject: Re: Struts 2 Custom Validation > > You mean a form with a password field and a confirm password field and > validation that they match? > > @FieldExpressionValidator

Re: Struts 2 Custom Validation

2008-02-27 Thread Randy Burgess
008 16:48:05 +0530 > To: > Subject: Struts 2 Custom Validation > > Hi all, > > > > Can someone tell me how to achieve client side validation in struts 2 with > custom validators > > It seems that password conformation in client side is not possible wi

Struts 2 Custom Validation

2008-02-27 Thread Thaminda Karunanayake
Hi all, Can someone tell me how to achieve client side validation in struts 2 with custom validators It seems that password conformation in client side is not possible with the provided validators in struts 2. If we are to write a new validator in struts 2, what are the steps that we have t

RE: Custom Validation

2006-10-11 Thread Dave Newton
From: Puneet Lakhina [mailto:[EMAIL PROTECTED] > I said: > > There are any number of ways around this; creating another action > > mapping (perhaps just a forward) is one way. > Forward wont do I need to get things from a DB before displaying the page. Obviously that won't work then. > > Turning

Re: Custom Validation

2006-10-11 Thread Puneet Lakhina
On 10/10/06, Dave Newton <[EMAIL PROTECTED]> wrote: > From: Puneet Lakhina [mailto:[EMAIL PROTECTED] > Is this the wrong way of doing things?? "Wrong" seems a bit strong. There are any number of ways around this; creating another action mapping (perhaps just a forward) is one way. Forward w

RE: Custom Validation

2006-10-10 Thread Dave Newton
> From: Puneet Lakhina [mailto:[EMAIL PROTECTED] > Is this the wrong way of doing things?? "Wrong" seems a bit strong. There are any number of ways around this; creating another action mapping (perhaps just a forward) is one way. Turning off automatic validation and running it manually (for inst

Custom Validation

2006-10-10 Thread Puneet Lakhina
Hi, I have an action which extends DispatchAction. So i basically have three methods, one for displaying the page before creating a new request, one for accepting the submit of a new request and one for accepting the submit of an update request. Now i dont want validations to occure when im only d

RE: index value in custom validation message ?

2006-09-29 Thread Tejesh Shetty
PROTECTED] Sent: Thursday, September 28, 2006 6:09 PM To: Struts Users Mailing List Subject: Re: index value in custom validation message ? Not sure if I understand what the issue is. In validator terms there is no requirement that what you define in a element be anything other than a regular java

RE: index value in custom validation message ?

2006-09-29 Thread Tejesh Shetty
2006 6:09 PM To: Struts Users Mailing List Subject: Re: index value in custom validation message ? Not sure if I understand what the issue is. In validator terms there is no requirement that what you define in a element be anything other than a regular java bean. So as I understand it you have an A

Re: index value in custom validation message ?

2006-09-28 Thread Niall Pemberton
. Thanks. TJ. -Original Message- From: Niall Pemberton [mailto:[EMAIL PROTECTED] Sent: Thursday, September 28, 2006 12:03 AM To: Struts Users Mailing List Subject: Re: index value in custom validation message ? Theres nothing in struts to help you do this - but the extends val

RE: index value in custom validation message ?

2006-09-28 Thread Tejesh Shetty
28, 2006 12:03 AM To: Struts Users Mailing List Subject: Re: index value in custom validation message ? Theres nothing in struts to help you do this - but the extends validator can but it only does server side - see the indexed example: http://www.niallp.pwp.blueyonder.co.uk/strutsvalidatorextends.

Re: index value in custom validation message ?

2006-09-27 Thread Niall Pemberton
Theres nothing in struts to help you do this - but the extends validator can but it only does server side - see the indexed example: http://www.niallp.pwp.blueyonder.co.uk/strutsvalidatorextends.html#indexed Niall On 9/28/06, Tejesh Shetty <[EMAIL PROTECTED]> wrote: I am using struts 1.2.8, an

index value in custom validation message ?

2006-09-27 Thread Tejesh Shetty
I am using struts 1.2.8, and I am validating an indexed property and everything works just fine. When validation fails for an item I want to display action message saying Item is required, I was finding a way to do that couldn't find anything. Can anyone please suggest how to get this working?

custom validation

2006-08-25 Thread Arun
methods sounded as if they would be helpfull for in getting the listitems. Is it possibel for me to get it done? if so how? Please tell me? Which book is the best such tasks? Thank you all. -- View this message in context: http://www.nabble.com/custom-validation-tf2164335.html

Custom Validation Doesnt Work

2006-08-22 Thread Chetan Pandey
Hi All: I have the following Code in my Custom Validation class: if (propertyVO != null) { System.out.println("propertyVO != null.Hence Errors. Will return false"); errors.add(field.getKey(), Resources.getActionMessage(request, act

Custom Validation doesn't add

2005-08-04 Thread Franz-Josef Herpers
Hi, I ran into a strange problem with the validation of form input that includes an uploaded file in Struts 1.2.7. I wrote a custom validation method for validating the file size of an uploaded file: public static boolean validateFile(Object bean

Re: problem in custom validation method

2005-03-04 Thread Sivakumar Santharam
Niall Pemberton blueyonder.co.uk> writes: > > The validation method signatures in Struts 1.2 changed from ActionErrors to > ActionMessages, but it looks like you're trying to use a Struts 1.1 format > method with Struts 1.2. > > Try changing your method signature to use ActionMessages. > > Nia

Re: problem in custom validation method

2005-03-04 Thread Sivakumar Santharam
> > Niall > > - Original Message - > From: "Erik Weber" mindspring.com> > Sent: Thursday, March 03, 2005 11:23 PM > > > Geez, thanks Niall. I've been posting custom validation examples that > > wouldn't work with 1.2 and didn&#x

Re: problem in custom validation method

2005-03-03 Thread Niall Pemberton
[EMAIL PROTECTED]> Sent: Thursday, March 03, 2005 11:23 PM > Geez, thanks Niall. I've been posting custom validation examples that > wouldn't work with 1.2 and didn't realize it. Please let me know if > there are any other si

Re: problem in custom validation method

2005-03-03 Thread Erik Weber
Geez, thanks Niall. I've been posting custom validation examples that wouldn't work with 1.2 and didn't realize it. Please let me know if there are any other significant validator plugin changes from 1.1 to 1.2. Erik Niall Pemberton wrote: The validation method signatures in Str

Re: problem in custom validation method

2005-03-03 Thread Niall Pemberton
The validation method signatures in Struts 1.2 changed from ActionErrors to ActionMessages, but it looks like you're trying to use a Struts 1.1 format method with Struts 1.2. Try changing your method signature to use ActionMessages. Niall - Original Message - From: "Sivakumar Santharam"

Re: problem in custom validation method

2005-03-03 Thread Sivakumar Santharam
> On 2005-03-03 14:28:52 -0500, Sivakumar Santharam gmail.com> said: > > > I am using struts 1.2.4 I created a new custom validation method in a > > validator class. I added a new validation rule to the > > validator-rules.xml file and new validation definitions to t

Re: problem in custom validation method

2005-03-03 Thread Bill Siggelkow
; said: I am using struts 1.2.4 I created a new custom validation method in a validator class. I added a new validation rule to the validator-rules.xml file and new validation definitions to the validation.xml file. I get the following error when the custome validation method is called. When I tr

problem in custom validation method

2005-03-03 Thread Sivakumar Santharam
I am using struts 1.2.4 I created a new custom validation method in a validator class. I added a new validation rule to the validator-rules.xml file and new validation definitions to the validation.xml file. I get the following error when the custome validation method is called. When I tried to