5 Replies Latest reply on Feb 22, 2011 4:19 AM by ramram888

    Disabling richfaces form

    ramram888

      Hi All,

       

         I have a scenario where I want to the form to have a readOnly property. The form tag has no property readOnly or Disabled. Is there any way to achieve this in richfaces?

       

       

      Regards,

      Ram

        • 1. Disabling richfaces form
          ilya_shaikovsky

          you should just disable all the commands and inputs using corresponding attributes.

          • 2. Disabling richfaces form
            javaxchange

            Hi,

             

            There is no option to disable the form. If your requirement is to disable all the components inside the form, you have to do it individually by using the disabled property of each component pointing to same backing bean variable.

             

            Rgds,

            Sreejith.PS

            • 3. Disabling richfaces form
              ramram888

              Hmmmm this seems a problem,

              Because I have to do it in a dynamic way rather than doing a disable on every component of the page.

              • 4. Disabling richfaces form
                ilya_shaikovsky

                you could use two ways.. expose the controls as custom facelets and add all the attributes which should be bulkly applied there. Then you could use it on the pages instead of original without additional definitions.

                 

                or write custom tag which will apply the needed options for all child components.

                • 5. Disabling richfaces form
                  ramram888

                  Hi Ilya,

                   

                    You mean by creating a custom tag or custom facelets, is that I create my Own <h:customForm> tag that contains the readonly feature?

                     Is there any example on your proposed methods?

                   

                     Thanks for the Help.

                      

                  Regards,

                  Ram