4 Replies Latest reply on Mar 30, 2012 6:36 PM by Federico Martinez

    Manage a clean event for the fileupload component in Richfaces 4.1

    Luca Stancapiano Expert

      Hi... I'm triing to manage the deleting of an item with the fileUpoad component in Richfaces 4.1. Here the my example:


        <rich:fileUpload fileUploadListener="#{fileUpload.listener}"

        addLabel="Click here" maxFilesQuantity="2"


             <a4j:ajax event="uploadcomplete" execute="@none"

                           render="myPanel" />

             <a4j:ajax event="clear"

                           listener="#{fileUpload.clearData}" />



      When I choose a file and I delete it, this method of my FileUpload class is executed:




      public class FileUpload implements Serializable {




          public void clearData() {





      How do I pass the parameter of the chosen file to my method?