You need to sign in to do that
Don't have an account?
Chirag Mehta
How to Generate HTML form(s) (with a specified action and set of hidden fields) dynamically
I want to generate HTML form(s) (with a specified action and set of hidden fields) dynamically i.e., based on user action on main form sub/child forms should get added
To make it more clear,
Main Form: Prompt to enter file information and description
Sub Forms: As soon as someone clicks Add file button on Main Form, sub/child forms need to be dynamically created and added in the below Attachments data table
Data table gets generated using controller, but dynamic form generation with hidden fields (input type file and submit button) seems not feasible. Any help would really ease my work, so request to please update that how can we generate HTML forms dynamically.
To make it more clear,
Main Form: Prompt to enter file information and description
Sub Forms: As soon as someone clicks Add file button on Main Form, sub/child forms need to be dynamically created and added in the below Attachments data table
Data table gets generated using controller, but dynamic form generation with hidden fields (input type file and submit button) seems not feasible. Any help would really ease my work, so request to please update that how can we generate HTML forms dynamically.
Best Answer chosen by Admin (Salesforce Developers)
Saurabh_Rawane
Declare a Page Block Section in your VisualForce Page, on Click of Add File rerender the page block section, have repeat tag inside the Page Block Section which dynamically adds forms into your page.
If anyone else have a better way of doing this, please suggest.
Thanks
Saurabh