US States Picklists Values

How many times have you had to make a picklist for the US states on a CRM 4.0 form? Well, rather than having to manually add each of the 50 states (52 if you count DC and Puerto Rico), I've got an XML file pre-made with the values of the US States that I copy into the customizations.xml for the particular picklist attribute I'm editing. I thought I'd share it here to save you some time as well.

Download it here.

To use it, export the XML for the entity you are working with, and open it in Visual Studio or your favorite XML editor (Notepad will work). Do a find to locate the picklist attribute you want to edit, and look for the node under it. It should look something like this:

Copy the contents of the downloaded file and then select everything from the starting
tag to the ending
tag in the customizations.xml and paste the contents of your clipboard into it. Verify that the XML looks correct, save your customizations.xml and import it back into CRM. Publish the entity and, voila, you have all 50 states available from your picklist.
UPDATE: Due to popular demand, I've also posted a similar text file that includes the countries of the world (265 of them). Note that this list has the United States and Canada listed first and second, with the rest of the world's countries in alphabetical order.


Mario Raunig said...

thanks matt! there is a picklist-generator tool on my blog that has a couple of ready to use lists including US states, languages, ...

Matt Wittemann said...

Nice tool, Mario. Thanks for the link.

ICU MSCRM © 2004-2009