Tallan Blog

Tallan’s Experts Share Their Knowledge on Technology, Trends and Solutions to Business Challenges

Posts Tagged "Forms Development"

Using JavaScript with SharePoint form fields

Using JavaScript in SharePoint forms enables developers to quickly customize the “look and field” and the behavior of a SharePoint form (Display, New or Edit form). It’s quick because you will see the effect directly on the form and given that you are embedding the JavaScript properly (putting the script in a content editor web part), you can also easily transport your code from development to production environment.
I recently have a chance to modify some SharePoint form fields thru JavaScript and would like to share my overall experience using JavaScript:

make a text field readOnly: my first attempt is by setting the disabled property to true with no success, the correct answer is document.getElementById(‘your_control_id’).readOnly = true;
make a checkbox field readOnly is more complicated, the readOnly property doesn’t exist/work, so I keep on researching and finally have this:

function makeReadOnly()
return false;
if (document.getElementById(‘your_control_id’).type ==…

Building a Custom Workflow Initiation Form Using Visual Studio

I first want to mention that I learned how to do this by following the four part workshop written by Robert Shelton. This is a very comprehensive workshop that gives you access to all of the source code and documentation. Where Robert’s workshop walked you through building a complete workflow in Visual Studio including the Association and Initiation, my particular needs at the time were focused solely on an Initiation form. In this post, I will attempt to condense this lesson as concisely as possible.