Setting up our Environment
First thing first, open your CRM 2011 development environment and browse to an account form. Once the account form is open, hit F12 on your keyboard. A window should popup that looks like this:
If instead, you see the window in the bottom of your browser page. Click the little “Unpin” button shown here:
This is IE Developer Tools and if you haven’t used this in the past, then I hope you enjoy not having to save/publish/refresh/test nearly as often. To start, we’re going to see how many fields we have on the form. When inside of the CRM form, we’d use something like:
But when we’re inside Developer Tools, we actually have a different context. So we need to click on the “Console” tab and execute:
Anything we want to execute on the form, we can do by simply prepending “frames.” in Developer Tools to get the proper context. This allows us to write and test code instantaneously, which is a huge timesaver.