Hi All, I am trying to user Validation framework with Struts2 but struck at a point,here are the details.
I am developing a import service which includes various steps like 1) Showing number of import options 2) Showing number of elgible files for the import (Import type selected in step one) for all this i have created only one action with multiple methods which is doing all the job.now in the second case when user select a file,i am trying to place a validation for empty field but since property file is outside of all he methods so the validation is working for all methods e.g i do not want the validation to execute for step1 but it is even getting executed for step one (since file will be selected in step 2 so step1 is always fails) is there any way to organise validation so that it should only execute for a specific method inside the Action here is my validation code @RequiredFieldValidator (type=ValidatorType.*FIELD*,message="Please select a file for import") *public* String getSelectedFile() { *return* selectedFile; } any help in this regard will be appriciated