Filtering Option Sets

Slalom Consultant Xavier Vargas

Xavier Vargas has worked as a CRM consultant with focus on the Microsoft Dynamics CRM platform for the last seven years. He currently works for Slalom Consulting helping build and maintain a first-in-class team in Dallas that enables his clients to win on all of their CRM initiatives and strategies.

Recently we ran into the need to filter option sets dynamically based on what Business Unit a user is in. Imagine the scenario where you have a dozen or so business units, each with a unique sales process. If you want to leverage the out of the box reporting and use the Sales Stage field, you’ll soon find that you have 50+ values in that drop down. At best this is a nuisance for end users, at worst an end user might end up inadvertently selecting an invalid value.

The following snippet of code allows us to filter an option set based on the passed in Business Unit name. An array of values is selected and any value in the option set that is not in the array will be removed. The result is a nice and tidy drop down with only those values we need:

Slalom Consulting - Xavier Vargas: Filterine Options Sets

Happy CRMing!

Slalom Consulting’s Dallas office Slalom Consulting's Project & Program Management focus
Learn more about our Dallas office Learn more about Slalom Consulting Customer Focus

subscribe by emailSubscribe to be emailed about new CRM posts

Dynamics CRM 2011 Report Development using FetchXML

Slalom Consultant Jayson Goldinger

Jayson Goldinger is a Slalom Consultant based in Denver, CO, and a member of the Slalom National CRM practice. His work revolves around Microsoft Dynamics CRM including configuration, customization, report development, and integration. He is also recognized as a Scribe MVP.

The inability to have custom reports was one of the biggest drawbacks of Dynamics CRM online when it was first released. Fortunately Microsoft has addressed this issue in the release of Dynamics CRM 2011. However, there is one small catch. The catch is that you have to use FetchXML (which is a proprietary query language that is used in Microsoft Dynamics CRM) for your SRS report query.

In my opinion one of the most powerful features of reporting in Dynamics CRM is the ability to use Advanced Find to “pre-filter” the data sent to the report. As a report writer of a number of years, I was always frustrated by the moving target of parameters that a user might request. When you get more than two or three, the report becomes a little difficult for the end user to use. By taking advantage of the “pre-filtering” with Dynamics CRM and Advanced Find the options of parameters become almost infinite and as a developer I only need to worry about one thing–setting up the option of “pre-filtering” in my report. It may seem like a difficult task but it is actually quite simple. I’ll walk through the steps. Read more of this post

Delete Field Data Via Workflow in Dynamics CRM

Mass edit is a great feature in CRM. You can run an Advanced Find to query for a list of potential records to update and edit on the fly. The only problem with this arises when you want to delete data. Unfortunately, the mass edit is additive, so any edits will be to add data, not remove.

Slalom Consultant Xavier Vargas

Slalom Consultant Xavier Vargas has worked with Enterprise CRM customers in numerous verticals. Based in Dallas, He has also delivered training engagements as an MCT (Microsoft Certified Trainer).

Enter the workflow. Through the use of a simple workflow, we can go in and selectively delete field data.

Create a new workflow that is run on-demand. In the workflow, add one step to update record. Within the properties, highlight the field you’d like to clear, then select the “Clear” value from the dropdown on the right.

Highlight field

SELECT CLEAR ON THE RIGHT

Select 'Clear'

THIS IS WHAT THE FIELD NOW LOOKS LIKE

The finished workflow should look like this: Read more of this post

CRM Field Masking with JQuery

Slalom Consultant Xavier Vargas

Slalom Consultant Xavier Vargas has worked with Enterprise CRM customers in numerous verticals. Based in Dallas, He has also delivered training engagements as an MCT (Microsoft Certified Trainer).

It’s always a good thing to make the user experience as nice as possible. One thing missing from CRM is the ability to mask fields. You’ve probably seen this online on sites that ask for your phone number or social security number where the text box already contains the hyphens in the necessary spots.  This clues the user in as to what format you’re expecting from them and leads to cleaner data.

Recently I had a client that needed all their zip codes to be entered along with the carrier code, which is the 4 number suffix at the end of a zip code. I figured this would be a great opportunity to implement some field masking.

Using a JQuery masking plugin written by Josh Bush (which he has also posted as a GitHub project) I was able to add a single line function to define my masking. To do the same, download this file and upload it to your CRM system as a web resource. Disclaimer: neither I nor Slalom Consulting has any relationship with Mr. Bush or his code—before using it please examine and evaluate the code yourself to determine whether it is suitable for your use, and use at your own risk.

Next, jump onto the form that you want to add a field mask to and add Read more of this post

Multi-Select Option Sets in Dynamics CRM

Slalom Consultant Xavier Vargas

Slalom Consultant Xavier Vargas has worked with Enterprise CRM customers in numerous verticals. Based in Dallas, He has also delivered training engagements as an MCT (Microsoft Certified Trainer).

To start off this blog, I figured I’d show you a new twist on an old trick. Microsoft Dynamics CRM doesn’t support multi-select option sets out of the box. In order to create one of these fields, we have to do a bit of JScript hackery. This is all completely unsupported but gets the job done.

So let’s jump right in. First thing you’ll need to do is create the option set that you want to convert to a multi-select:

Create your option set

`

Define the option set values

`

Next we’ll create a shadow field that will actually hold the Read more of this post

Woot – I Got Published!

Slalom Consultant Derek Martin

Slalom Consultant Derek Martin is an accomplished Microsoft systems developer and integrator, experienced in developing and deploying SharePoint and CRM solutions, integrating line of business applications, and leveraging existing infrastructure investments.

Can I brag?  I was very excited to learn today that I got published – TWICE!  It isn’t my first time being published but is exciting none-the-less! Check me out:

Here (whitepapge: The Challenges of Multitenant-aware CRM Instances with Entity and Function Commonalties)

and

Here (Top 6 Misconceptions About Cloud Computing–I wrote the six myths although it doesn’t have my name on it).

Pretty excited – it has inspired me to write up some more stuff…any topic suggestions?

PS – Just talked to my mom – she’s proud :)

Follow

Get every new post delivered to your Inbox.

Join 217 other followers