locked
Web Part javascript access elements in Main form RRS feed

  • Question

  • I have a sharepoint list. In the New Item page, I added a new HTML web part with just a command button. When I click the command button, I want to retrieve the details entered in the main form (by main form I mean the fields that are entered for the list item), and throw an alert box with the retrieved detail

    I have edited the web part source code and understood where I can add some javascript for the command button onclick event. But in the javascript, how can I get the value entered in the main from fields? Can I use something like getElementByID in the javascript? if yes, what will be the ID name for the fields in the main form?

    Friday, December 16, 2016 8:43 PM

Answers