Category: Tips

  • eXtreme CRM Tool Challenge Winner: Tanguy!

    Unfortunately I wasn’t able to attend the eXtremeCRM event in Barcelona this year (“the Woodstock for CRM Rockstars”), but I’ve been keeping an eye on the buzz in Twitter around the #eXtremeCRM hashtag. Although it’s not exactly the same as enjoying live CRM geek talk over some tapas & cerveza, for anyone interested in hearing the latest news and tips around Dynamics CRM this is certainly a better pastime than any reality shows on TV.

    There’s a bit of a reality TV style competition every year at eXtremeCRM, called the the eXtreme App Challenge, where the participants have 24 hours to build an application leveraging the Dynamics CRM platform. The idea is of course to showcase the potential for extremely rapid app development where an idea can transform into a functional application overnight, thanks to all the “plumbing” that CRM platform already provides you. Well, I’d like to just point out that it’s not just the technical platform of Dynamics CRM that makes it such an excellent tool for delivering real life business solutions. There’s also an awesome community formed around Dynamics CRM that at the end of the day powers the platform in an equally important way as the SDK or the bits of code delivered by Microsoft. Here’s one excellent example of it:

    While spending the afternoon coffee break on Tweetdeck yesterday (like I far too often do), I came across one picture tweeted by Jonas Rapp from an eXtremeCRM session that demonstrated how to manipulate the CRM 2013 default dashboard setting via the Sitemap XML. The dashboard settings behavior is one of the less known areas of the latest Dynamics CRM version, although it has been covered in CRM Team Blog (which I was of course quick to point out, being the “certified Smar As*” that I am).

    The guru of CRM, Adam Vero, jumped in on the discussion and pinged the lord of the rings CRM tools, Tanguy Touzard, with a suggestion on making this setting a part of his Sitemap Editor, included in the ever growing XrmToolBox. Things kind of escalated from there and just a moment ago there was a new blog post published: Change the default dashboard in Dynamics CRM 2013 with XrmToolBox SiteMap Editor plugin.

    XrmToolbox default dashboard

    What just happened there? Let me summarize it for you:

    10.2.2014 12:47 – A tweet about a less known feature in CRM 2013 Sitemap XML presented at eXtremeCRM.

    11.2.2014 16:39 – The announcement of a free tool to configure the setting via a graphical, user friendly UI.

    That’s 27 hours and 52 minutes “from tweet to complete”. Folks, we have a winner and you all should know him by now:  Tanguy! Please show him the appreciation he deserves by dropping by his sponsor page on your way to collect the latest XrmToolBox download. Thank you.

    We’ve all heard (and some of us even blogged) about the rapid release cadence that Microsoft is nowadays pursuing via their cloud-first strategy of pushing out new releases of Dynamics CRM every 6 months (12 for on-premises). Still, all of this pales in comparison to the speed at which the community around the product, powered by social networks like Twitter and open source galleries like CodePlex, can deliver their own little “hotfixes” to the platform.

    While browsing through my stacks of CRM blog feeds and weeding through the #MSDYNCRM tweets, it’s sometimes too easy to forget that not everyone knows about the great tips and time saving tools that are available out there. It’s almost scary to think that in reality there are many people working with Dynamics CRM professionally who haven’t yet discovered the many ways in which the CRM platform could more easily be leveraged to deliver better solutions for customers in a shorter period of time – if only they knew how.

    There’s a very simple way how each and every one of us can make a difference here: if you come across a useful piece of information that helped you solve a problem you’ve faced while working with Dynamics CRM, please pass it on. You don’t have to develop a set of advanced configuration tools, or even build an app in 24 hours – just share what you’ve seen, heard or discovered. Then we can all be the winners.

  • Finding Advanced Find in CRM 2013

    The user interface of Dynamics CRM has been cleaned up quite a bit in the latest 2013 version. The number of buttons visible to the user has been greatly reduced in the browser client. Another significant change from a usability perspective is that Dynamics CRM now operates like any other web application or website: within a single browser window, allowing you to navigate back & forth with the browser’s native buttons. The combination of these two factors has however lead to one side affect that may cause the users familiar with previous Dynamics CRM versions to ask the question: “Dude, where’s my Advanced Find?”

    In CRM 2011 the Advanced Find was always available in the main window of CRM. Unless you resized the window to a small enough size and made the Data tab of the CRM 2011 Ribbon collapse into a single flyout button, it was pretty easy to spot the familiar binoculars icon that represented Advanced Find. Being one of the most powerful features of the Dynamics CRM application, this button will have surely become familiar to all power users of CRM over the years.

    CRM_2011_Advanced_Find

    In CRM 2013 the Advanced Find feature is not always so easy to locate. I have observed quite many experienced users to struggle with locating the menu after the system has been upgraded. Also, when I was recently studying the Google search terms that had lead people to visit my blog, “CRM 2013 Advanced Find” and its variations appeared three times in the Top 20 searches. Since the Advanced Find feature itself has not really changed at all in the 2013 version compared to previous releases, I presume many of the questions people have in their mind while reaching out to a search engine may be related simply to “how to find Advanced Find” (as “meta” as that may sound).

    If that’s the question you have, then let me first explain a bit about the logic behind the standard behavior of the new Dynamics CRM 2013 UI in different areas of the application. Then I’ll show you an alternative method that will make it much easier to launch Advanced Find from any place inside CRM.

    Standard Navigation Experience

    When you open up the Dynamics CRM 2013 browser client with the default settings of a fresh new CRM organization, you’ll be taken onto the dashboard page. Here the button for opening Advanced Find is displayed prominently as one of the actions on the Command Bar, just like it would have in CRM 2011.

    CRM_2013_Advanced_Find_1

    If we move forward to a list view of any entity, the Advanced Find button no longer appears directly on the page. Instead the user needs to click the ellipsis (three dots) to reveal the “more actions” menu, where one of the actions launches Advanced Find into a new popup window. Another alternative would be to expand the view selector menu and choose the last option of “Create Personal View”, which will also lead the user to the Advanced Find window.

    CRM_2013_Advanced_Find_2

    How about if we’ve navigated onto a record of an entity, such as a contact, and then realize we want to perform a search on other similar records? If we now repeat the same action of expanding the Command Bar menu via the ellipsis, there is no longer an option launch Advanced Find from here. Instead we’d need to go back in our steps to the Contact list view by clicking the label in the Navigation Bar. This would then land us on a window where the option is again available.

    CRM_2013_Advanced_Find_3

    In a way this behavior makes sense, since the Command Bar actions visible on the record detail page are all related to the single record in question. Advanced Find also isn’t considered a “global” action in CRM that would be always present in the Navigation Bar (like the gear icon for opening the personal options menu), but rather it only makes its appearance when looking at a view of records (with the dashboard page being an exception to this rule). As Advanced Find really is a tool for building views, it is shown within this context of existing views for any record type.

    Creating a Shortcut Button for Advanced Find

    If you need to frequently work with views in Dynamics CRM, to perform searches on records, study different data columns than the system views offer or perform data analysis of any kind, you might find yourself reaching out for Advanced Find quite often. Instead of having to first perform a check on what is the current page’s context and then determining the steps needed for launching Advanced Find, wouldn’t it be more convenient to just have a persistent button available that would always take you to that window?

    Although Dynamics CRM itself doesn’t offer a direct way to bookmark the Advanced Find page, you can still easily grab its URL. In Internet Explorer, once you’ve opened up Advanced Find, press Ctrl+N to open it in a new window that contains the full browser controls. Now you can add it as a bookmark and place it on the Favorites bar (right-click on the top of the IE window to enable the bar if it’s not visible). The URL will be in the form of http://[servername]/[organizationname]/main.aspx?pagetype=advancedfind in an on-premises Dynamics CRM environment.

    CRM_2013_Advanced_Find_4

    Wait, don’t leave just yet! There’s more to it! The URL will be a static link that points to your current CRM organization. If you ever need to work with more than one CRM environment (such as development, test, production instances), then that bookmark will not be of any help in the other organizations. Wouldn’t it be cool to have a context sensitive button that would always take you to the Advanced Find window of the CRM environment you’re currently accessing? (more…)

  • Making Better Use of Business Process Flow Data

    CRM 2013 Business Process Flows (BPF) have been designed to support a scenario where the same transactional records (opportunities, cases, custom entities like projects) can follow alternative process steps depending on the business logic required. For example, you can use the same opportunity entity to support the sales processes of two departments that are operating in very different markets and thus have different process stages as well as information content gathered within those stages.

    You can either limit the availability of BPF’s by CRM security role, so that a salesman in department A will always get the sales process A for the opportunity records he creates, or you can enable the users to see a number of different processes and let them choose the correct one via the Switch Process button on the Command Bar. In the latter scenario the Select Business Process Flow dialog window will present the available processes, like this:

    BPF_CRM2013_multiple_processes_1

    More processes will naturally mean more variety in the type of data your opportunity records will hold. Instead of a fixed number of stages in a specific order you’ll have opportunities that are following different sales processes with unique stages, which could easily lead to a situation where the CRM user may be comparing apples and oranges in the same entity view. How can we avoid such confusion in a multi-process environment? Hopefully this post will give you some ideas on the best strategy to manage your Business Process Flow data.

    Working with the Stage Category

    The officially recommended tool for making Business Process Flow stages visible in views and charts is the Stage Category option set. This is a field available on the Process Stage entity and you can select a value for it while editing the Business Process Flow process record.

    BPF_CRM2013_multiple_processes_2

    Basically what this field allows you to do is to standardize the stage values across different BPF processes. You can enter a different name for the actual stage in the BPF editor but still link it to a Stage Category value that is used in some of your other processes, too. Depending on your business, there may be different sales processes that would each contain a conceptual Propose stage but apply different terminology for it. That’s one problem that the Stage Category can solve.

    If you want to customize the list of values available for the Stage Category, just find the global option set under the Default Solution (Settings – Customizations – Customize the System) and update it like any other field. The new values will appear in he Business Process Flow editor after publishing the changes.

    BPF_CRM2013_multiple_processes_7

    When building a view to display the opportunities by stage, you’ll need to add a column from the related Process Stage entity to leverage this information. In the Add Columns dialog of Advanced Find, choose the aforementioned entity and select the Stage Category field from the list that appears.

    BPF_CRM2013_multiple_processes_3

    One limitation related to the view columns is that we can’t apply any sorting to the Process Stage field. That’s because it’s from a related entity and as a result it doesn’t appear as a possible field in the Configure Sort Order dialog. This means that our opportunity view can’t have the records nicely aligned per stage value, to simulate a pipeline, but instead we’ll need to rank them based on some field that’s directly available on the opportunity record itself.

    BPF_CRM2013_multiple_processes_6

    Grouping or Filtering by Business Process Flow

    So, we have the capability to merge stage values across different BPF’s into a single view. Pretty cool. Now, since different sales processes are often related to different types of product categories or business lines, what are the steps needed for creating an opportunity view that also displays the name of the BPF process chosen for the record? For example, if we want to group the revenue per process instead of process stage, which field do we need to add into the view?

    Sorry, there is no such field. Thank you, have a nice day.

    Excuse me, what?! Didn’t you just show how to harmonize the stage values across different processes? Surely there’s a way to un-harmonize things and break it down based on individual processes and stages?

    Well, stages yes, but processes, no. You see, there isn’t a direct relationship to the actual Business Process Flow process entity from the opportunity entity (or any other BPF enabled entity). While the system does store a GUID reference to the process and process stage records in the StageId and ProcessId fields, these are “unique identifier” type of fields that you can’t reference in Advanced Find query criteria. We could add them as a view column, but they’d just be gibberish like “3e8ebee6-a2bc-4451-9c5f-b146b085413a”.

    BPF_CRM2013_multiple_processes_4

    The Process Stage entity that we examined earlier is a parent entity of the opportunity and it can be accessed in Advanced Find, but it doesn’t contain any field that would specify the name of the process to which the stage belongs to. When selecting view columns in Advanced Find we can only go one level up, but luckily when building a filter criteria for the view we can query entities further away. This means we can reach the Process entity related to the Process Stage entity and find our Alternative Sales Process from there, as illustrated below. (Note that you’ll need to change the default lookup view to display the BPF processes, as otherwise you’ll only see workflow processes to choose from.)

    BPF_CRM2013_multiple_processes_5

    By adding this criteria we are able to build a view containing only opportunities from a specific Business Process Flow. To see the total pipeline revenue per each process we’d just need to switch between the views, or build a dashboard that contains one list/chart per process. Not quite as elegant as having a single chart grouping the revenue per process, but it’s still better than a mixed bucket of opportunities from all over the place.

    What if I told you there was a better way to do this than the out-of-the-box data model provides? Would you be interested in seeing its possibilities? Then you’re in luck, because that’s what I was going to write about next. (more…)

  • Expanding “Add Activity” Options on CRM 2013 Forms

    CRM 2013 has introduced many UI features that aim to reduce the number of different windows between which the user needs to navigate while performing everyday actions on records. Since customer relationship management systems are often focused on capturing the various interactions between the company and its customers, activity management is naturally a core feature that should be as smooth as possible in a CRM application.

    The refreshed entity forms in CRM 2013 contain the Social Pane (shown as “Notes Control” in the form customization UI due to legacy reasons) that shows three tabs of interaction data related to the record: Activity Feed posts (Yammer posts if available), activities and notes/attachments. In addition to a much richer rendering of the activity content than the previously available subgrids, there’s also an inline control available for adding tasks or phone calls directly on the main entity’s form. This provides quite a slick user experience that makes CRM appear very effortless to use for activity management.

    CRM2013_Activities_1

    What’s missing from the Social Pane then? Well, for starters, not all the activity types are available to be created via the Add buttons on the top of the control. We have phone calls & tasks available immediately, clicking the ellipses (…) button gives us email & appointment, and if we’ve added any custom entities into our solutions they’ll be presented here, too. However, if you’d want to add any of the other default activities for the record you’re working on, meaning a letter, fax, recurring appointment or a service activity, then you’re out of luck. The user would need to navigate away from the form by selecting the Activities menu from the Nav Bar, create a new activity record from there, find the Regarding record to reference on the activity, save it, then return back to the original record.

    Another limitation has to do with the inline editing experience of tasks and phone calls. When you create a phone call via the Social Pane, it will always be record as a completed activity. So, no chance for planning upcoming phone calls and setting up a reminder, unless you record it as a task instead. Another downside of the inline form is that it’s not customizable, which means we can’t display any custom category fields related to a phone call or task. When implementing a CRM system for tracking the activities of sales people and account managers, it is a very common requirement to have some compulsory fields added onto the activity entities that the user must fill to categorize and describe the activity before being able to complete it. Well, since the inline form will log a completed phone call right after clicking on OK, this isn’t exactly the optimal feature for those scenarios.

    Ribbon to the rescue

    While some parts of the new UI are not yet customizable in CRM 2013, we do still have a way to introduce additional features onto the entity forms via the Rib… sorry, Command Bar. Even though in its default setup the Command Bar looks like a stripped down version of the CRM 2011 Ribbon, it’s still built on the very same  Ribbon XML definitions and it supports most of the features from its previous incarnation. As we know, CRM in itself doesn’t provide tools for configuring the contents of the Ribbon, which is why someone just had to do something about it. That “someone” is CRM MVP Scott Durow and the “thing” is his awesome Ribbon Workbench solution that gives us everything imaginable for customizing the CRM 2011 Ribbons as well as the CRM 2013 Command Bar.

    Since many of the common features presented on the CRM 2011 Ribbon get hidden away once the CRM environment is upgraded to 2013, Scott has been covering several scenarios in his blog where this functionality is restored onto the Command Bar. Among these articles is a tutorial on how to restore the Add Activity buttons into a CRM 2013 environment. By following these steps documented by Scott we can enable the creation of letter activities while on an entity form, as well as provide a navigation path to opening the full form of a phone call activity to control the business required fields as well as activity status beyond the options that the Social Pane inline activity form gives us.

    To demonstrate the possibilities of modifying the default activity management features of CRM 2013, I decided to take Scott’s example and expand it a bit further. In his blog post Scott shows you how to make the activity buttons appear on the Command Bar, but due to the limitation of max 5 items being shown directly on the form and the rest being pushed away into the “more actions” menu, it’s not going to be very easy for the CRM user to discover their existence. What I did instead was add a new flyout menu, promote it to the top 5 items on the Command Bar and arrange all the “Add Activity” buttons inside it. The screenshot below shows how this has been configured while in the Ribbon Workbench UI:

    CRM2013_Activities_RibbonWorkbench

    How do we get the buttons to do what we want them to do, meaning creating new activity records like they used to in CRM 2011? Scott’s blog post contains all the details you need for making this happen, but since the inherent complexity of the Ribbon XML language can make it challenging to grasp how the various options relate to one another (I’ll be the first to admit I struggled quite a while with the task before being able to achieve the result I wanted), I’ll recap the main steps here for your convenience.

    First of all, we’re not creating a completely new command but rather customizing a native CRM platform command. While the activity buttons aren’t visible on the Command Bar by default, they do exist in the Ribbon definition and can be accessed in the Ribbon Workbench by switching from the Command Bar tab to the Ribbon tab (bottom left corner of the top menu) and navigating to the Form ribbon (since this is where we want the flyout menu to appear in our example). You’ll see the familiar Ribbon in the format that it would be shown, with the Activity buttons available under the Add tab. Yeah, not too many end users probably ever discovered that second tab of the ribbon on their own, which is why the simplified design of CRM 2013 is definitely a step in the right direction, even if it means us consultants need to do a bit more tweaking of the system to enable the relevant features.

    CRM2013_Activities_RibbonWorkbench_2

    Anyway, now that we’ve found the buttons, we can right-click on them and select “Customise Command”. Effectively what this does is it brings the commands like Mscrm.AddPhoneToPrimaryRecord available for us to reference in the custom buttons that we create. While we’re at it, we can also re-use the icons and labels from the native buttons in our custom flyout menu buttons. The one thing we need to change, however, are the Display Rule settings of the now customized commands, as the Mscrm.HideOnCommandBar rule would otherwise do just what it says and hide the buttons from our flyout menu when viewed on a refreshed UI form.

    As mentioned, please refer to the original blog post to guide you through the detailed configuration of the custom buttons. It will give you everything except the different layout, which is the flyout menu that you can see below. In practice this method allows us to create up to five traditional dropdown menus on the form’s Command Bar. We now have a button labelled “Add Activity” that will open up a list of different activity icons, which in turn will lead the user to the traditional full create form for the chosen activity type. It will pop open in a new window, allow the user to edit the details, then close the window and return back to the parent entity form. Just like in the “good ol’ times” of pre-2013 Dynamics CRM.

    CRM2013_Activities_2

    If you took a closer look at the flyout menu shown in the picture, you may have noticed one non-standard entry at the end of the list: Site Visit. What’s that? And why’s it under a menu section called “Quick Actions”? Thanks for asking, let me explain what it’s all about. (more…)

  • Similar Opportunity Analytics with CRM 2013 Quick View Forms

    A while ago when performing a requirements gathering session for the sales process functionality in a CRM implementation project, my client asked me whether Dynamics CRM was able to show information on the opportunity form about how similar opportunities had performed in the past. Thinking of an analogy from the world of consumer web apps, this would be a bit like Amazon’s feature where they show you similar items that other people had purchased after ordering the product you are currently thinking of buying.

    Similar_items

    My initial reaction to the request was “I wish we could do that, but you’re looking at either a significant chunk of custom development or a considerably more expensive piece of software to get that functionality”. After a moment of thinking about it, though, I realized that the new CRM 2013 version already had some platform functionality that could be leveraged for delivering such a feature under the right circumstances.

    Quick View Forms across multiple relationships

    Traditionally Dynamics CRM has been an application where you can show information from either the current record the user is working on or the child records directly related to it. It wasn’t until CRM 2011 that showing the related child records right on the entity form became a supported scenario. With CRM 2013 we’ve gained another important feature that we can use to expand the scope of information being shown to the user on a single form. The new Quick View Forms allow us to show several fields from the parent entity on the current entity’s form. Even better, the Quick View forms support the CRM 2011 subgrid feature, which also makes it possible to show information about the child records of the parent record on one of its other child records.

    “Whoa, that’s way more relationships that I can visualize in my head! What does all this actually mean?” No worries, these are not the type of features that would be immediately obvious to even the more seasoned CRM consultants. Let’s approach this via an example from the out-of-the-box configuration of the CRM 2013 case form. This new form contains a Quick View Form called Customer Details:

    Recent_Cases_CRM_2013

    The Quick View Form not only shows details about the customer account but also a subgrid of all the recent cases where this account has been the parent record. So, starting from the case record, we go one level up in the hierarchy to query the account record and then we come back down again to retrieve a list of child records for this account. The Recent Cases subgrid returns back to the same entity as where we start from, but this is not a requirement, as is demonstrated by another subgrid included in the same Customer Details Quick View Form that lists the recent activities regarding this account. Effectively we can show any entity information that is maximum two hops away from the current record and that share the common parent record.

    Applying Quick View Forms in customer segment analysis

    How could we leverage this feature in providing the CRM user some insights on how similar opportunities have worked out in the past? The key here is finding an entity that we can use for binding the different opportunities together and showing relevant information about them that will be helpful for the CRM user in deciding on the actions to take in pursuing the new sales opportunity. If it’s an existing customer that has done purchases in the past we could of course benefit from seeing this history, but assuming that we’re dealing with a scenario where repeat purchases are not that frequent, we should look for a different variable that could help us in surfacing the past sales analytics that can help us in winning the new deal in question.

    Let’s assume that we’ve got a customer segmentation model in place where we assign each new and existing account a segment value. The actual rules behind the segmentation process are beyond the scope of this article, but the one thing that’s critical here is that the segment information is stored in a dedicated “Segment” entity. This custom entity has a parental relationship to the account entity, which basically means that we can open a segment record and see all the accounts belonging to that segment. Now, because of the fact that each account has a value in the segment lookup field, we can also configure it so that every opportunity created for the account also inherits the segment value of that account. Effectively we’ll then have a similar 1:N relationship between the Segment and Opportunity entities as we have with Segment and Account. The end results and our target configuration will therefore look something like this:

    Account_segment_opportunity

    We need to have a bit of redundancy in our data model in order to be able to leverage the Quick View Form feature for our desired purposes. Technically we could determine the segment of the opportunity record just by examining the value on the parent account of that record, but we wouldn’t be able to reference it on the opportunity form customization UI. Therefore it is crucial that the segment value is carried over from the potential customer account onto the opportunity record, either through a relationship attribute inheritance or a real-time workflow that retrieves the value right after the opportunity record is created (preferably both, to cover all scenarios for opportunity creation). (more…)

  • Connecting to CRM Online OData feed with Excel 2013 Power Query

    The latest version of Excel contains a Get External Data menu option for linking the workbook to an OData data feed. Knowing that Dynamics CRM 2011 and 2013 both provide an OData endpoint, this would seem like a great option for retrieving data from a CRM Online based system for reporting purposes, since direct database connections aren’t available in the cloud. Unfortunately, if you try to enter the CRM Online OData URL as a feed link, you’ll get this error message:

    CRM_OData_feed_Excel_error

    “We can’t use the data from this feed.” Bummer. The reason behind the error messages is that Excel and PowerPivot have not been able to support the authentication mechanism required for accessing the CRM Online OData feed. There is a workaround that you could apply if you’ve got the CRM Outlook client installed on the same machine, as described in this video by Ed Martinez, but in general using PowerPivot for CRM Online reporting has been quite restricted.

    Power BI December 2013 Update

    Last summer Microsoft announced the preview program for Power BI, their cloud based business intelligence suite, containing tools for publishing reports in Office 365. The Power BI umbrella also covers client side components, including Power Pivot (now spelled as two separate words apparently) and Power Query, that bring new capabilities to Excel. To get an understanding of the features included or under development, I encourage you to watch this Power BI demo from WPC 2013, which definitely deserves the Coolest Tech Demo of 2013 trophy if you ask me.

    PowerBI

    The latest December 2013 Update for Power BI announcement mentions the following enhancements:

    “Power Query can now connect to more data sources:

    • Sybase IQ
    • Exchange
    • Dynamics CRM Online

    Hey, that last part sounds great! So, what does it mean in practice for us CRM people? Well, the Power BI Preview subscription still doesn’t provide the option to provision a CRM Online instance for the same Office 365 instance, so there’s not that much new things visible on the cloud side yet if you spin up a preview org. On the client side, however, there is now an updated version of Power Query Preview for Excel 2013 that gives us the possibility to finally connect to a CRM Online OData feed directly. Let’s explore that in more detail. (more…)

  • Address Copy Button with CRM 2013 Business Rules and Workflows

    Address Copy Button with CRM 2013 Business Rules and Workflows

    The default forms in Dynamics CRM only contain one set of address fields, but most organizations will need to surface at least the Address 2 fields for accounts and contacts to manage the different information for visiting address, mailing address, delivery address, invoicing address or whatever the business scenario.

    Sometimes it may be justified to have a bit of redundant information in your CRM database for practical purposes. For example, if you use the Address 2 fields for managing the mailing addresses for accounts where this is separate from the visiting address, it may be easier to have the mailing address fields populated also in scenarios where the values are identical to the visiting address. Otherwise the marketing assistant who is building target groups for mailing campaigns will need to perform some Excel sorcery to pick different address fields for different customers when extracting the data from CRM.

    If you’ve bought anything from online stores during the past 10 years, you’ve probably ran into a nice little feature on the checkout or registration forms where the system asks if you’d like to use the address information you entered into your customer profile also as the shipping address for the order. Often times this is presented as a checkbox field that you simply need to tick once, to save you the trouble of re-entering the same data the system already knows.

    Wouldn’t this be a nice feature to have also on the CRM account form? Let’s take a look at a form where both Address 1 and Address 2 fields are presented side-by-side. If we would have a “Copy to Address 2?” checkbox that the user could tick after having tabbed through the Address 1 fields and entering data into them, that would be quite an intuitive feature that the users would surely feel right at home with. On the account form it could look like this:

    CRM_2013_address_copy_account_1

    Now that we have our new custom field below the Address 1 fields, next we need to build the functionality for duplicating the field values from Address 1 to Address 2. So, please open you “Javascript for Dummies” textbook from page 47 and… Hey, wait a minute! We’re working with CRM 2013 now that has the great new Business Rules feature for situations like these! Forget what I said about scripts, instead go ahead to the account entity customization menus and add a new Business Rule for this form.

    On the “Copy Address 1 to Address 2” Business Rule we’ll set a single condition to monitor the value of our custom chechbox field. If the box is ticked, meaning the field value equals “Yes”, we’ll set the values of each visible Address 2 field on the form to be the same as what’s been entered into the corresponding Address 1 field.

    CRM_2013_address_copy_business_rule

    Once we publish our customizations and activate the Business Rule, we can try out the feature in practice. Let’s create a brand new account record to simulate the typical data entry process (although an existing account would work just as well). After we’ve entered the Address 1 information on the left column, the moment we tick on the “Copy to Address 2?” box we’ll see the address fields on the right side get populated with the same values in real time.

    CRM_2013_address_copy_account_2

    Great, we’re all set to move this into production now! Or are we actually? What happens when the user wants to go and edit the field values for Address 2? If we leave the “Copy to Address 2” box ticked, then our Business Rule will keep copying the values over to the Address 2 fields the next time the rule is evaluated. As we’d like to allow the user to leverage this copy feature to initially replicate the fields to Address 2 but perform the necessary changes to those values that are in fact different, such as editing the Street 2 field, we should somehow restrict when our field copy operation is triggered. (more…)

  • Enforcing Business Process Flow Fields with Real-time Workflows

    Enforcing Business Process Flow Fields with Real-time Workflows

    Earlier I demonstrated the new capabilities that Microsoft Dynamics CRM 2013 has introduced for workflow processes: showing error messages with real-time workflows. I covered examples of record assignment, merging duplicate accounts and stopping unwanted updates in the Mobile Express client. This time I’ll take a look at how the error message feature can be leveraged in managing the sales process on opportunity records.

    The new Business Process Flows in CRM 2013 provide the possibility of setting fields in a stage as required. This is a nice advancement over the previous platform functionality that only allowed you to set fields as business required per entity, since now we can dynamically control the stage at which we will require the user to input the information onto a form. It’s very typical that a user wouldn’t yet have much details available about a sales opportunity when first entering the information into the CRM system, so it makes total sense to not ask too many questions initially. After all, you can make a field required, but if the user simply doesn’t possess the information asked in it, he or she may just enter dummy data into the field to meet the technical minimum requirements.

    CRM_2013_business_process_flow_editor

    Looking at the default opportunity sales process that comes with Dynamics CRM, we have a number of bit fields in the Close stage that indicate tasks the opportunity owner should complete before closing the opportunity. In the Business Process Flow editor we can tick a box and set these fields to be required. What does a required field in the Business Process Flow then mean exactly? It simply means that you can’t move the record forward from that stage until a value is entered in the field. In the case of bit fields (two options) the value should be set to Yes (ID 1) to meet the criteria.

    OK, sounds logical, but what about if we’re already in the last stage of the process? How is the requirement level enforced if there are no more stages to move to? The answer is: it’s not. Since the actual closure of an opportunity as Won or Lost is not a stage in the process but rather a change of the record status, Business Process Flow has nothing to do with it. We can observe this behavior by setting a field required in a process stage and then navigating to a test opportunity and attempting to close it as Won. In our example, the File Debrief field has been set as required in the Opportunity Sales Process, but the system still allows the user to close the opportunity without entering data into this field.

    CRM_2013_business_process_flow_opportunity_close

    “That sounds like an unfortunate gap in the business logic, I guess we’ll need to get a developer to write a plug-in for us to stop the status change operation if required data is missing.” Hold it right there, mister! We’re dealing with Dynamics CRM 2013 here, which means we can build the equivalent feature with a real-time workflow process! No custom code needed for such a simple task, as long as you know how to leverage the new interactive nature of synchronous workflows.

    Let’s create a new workflow on the opportunity record and set it to start when the record status changes. We’ll configure it to be run as “after” the event, since we’re interested in capturing the new status value of the record. In the workflow criteria we’ll define that we want our business logic to apply if the opportunity is being set as Won but the File Debrief field has not bee set to Completed. Since this is a real-time workflow, we can add a step where we set the process to be stopped as Cancelled and then define an error message in that step’s properties. This will then be presented to the end user who is triggering the status change event if the workflow criteria is met.

    CRM_2013_workflow_opportunity_close

    Now, let’s go to our test opportunity, re-open it and attempt to close it without marking the File Debrief field as Completed. When clicking the Close as Won button on the opportunity form command bar we’re presented with the standard, non-customizable Close Opportunity dialog window asking us about the Actual Revenue, Close Date and so on. Since we’re so excited about having won the opportunity we’ve completely forgotten that there were still tasks we needed to complete before we’re allowed to close it off from the sales pipeline.

    CRM_2013_business_process_flow_opportunity_close_2

    Once we click OK, a new dialog window is presented: the Business Process Error prompt, along with the error message that we defined in the Stop stage of our workflow process. The opportunity close event is rolled back and we can return to the opportunity form to see what steps of the process we had neglected.

    CRM_2013_business_process_flow_opportunity_close_3

    As I mentioned in my previous article about the new business process automation capabilities of CRM 2013, Business Process Flows are essentially a process map that is meant to guide the user through the stages. It cannot actually perform any automated tasks by itself, nor enforce any rules apart from the changing of the stage through the visual business process control at the top of the form. To implement this type of functionality you should look into Business Rules and Real-Time Workflows instead.

  • Using Real-Time Workflows to Show Error Messages

    Using Real-Time Workflows to Show Error Messages

    In CRM 2013 we now have the option of setting a workflow to be run synchronously, also known as a real-time workflow. This opens up great new possibilities to leverage workflows in designing automated processes and providing immediate feedback to the end user when CRM data is created or updated. Having the workflow process executed in real-time also provides one additional capability that traditional, asynchronous workflows can’t handle: stopping the transaction from taking place.

    Configuring Custom Error Messages

    Similar to synchronous plug-ins, real-time workflows can present a Business Process Error dialog to the user when the operation being performed is breaking the rules of the configured business logic. As the real-time workflows execute in the current transaction, they have the power to roll back the changes that the user is trying to perform, whereas an asynchronous workflow could only observe what had already taken place.

    How does this work in practice? Let’s explore the feature by setting up a very simple workflow rule to verify the owner of a record, in this case the Project Manager (owner) of a custom Project entity. When creating the workflow we’ve unchecked the “run this workflow in the background (recommended)” checkbox and thus defined it to run in real time. (If you forgot to do this, just reach for the “Convert to a real-time workflow” button on the toolbar, as the form checkbox can’t be edited directly). We’ll attach the workflow to the assign event of the entity.

    Real-Time_Workflow_rule

    In the workflow rule criteria we’ll perform a check that the Project Manager has the necessary qualifications for the job. If not, we will  stop the workflow and set its status to be Canceled. What’s new compared to CRM 2011 workflows is that we can set a Status Message for the workflow cancellation. Rather than just being a behind the scenes log entry, this text field’s contents will actually be presented to the user if the real-time workflow process is cancelled. This is therefore the place where you should provide instructions on why the cancellation took place and how the user can avoid it.

    Let’s activate our workflow, go to an existing project record and attempt to assign it to a less competent CRM project manager, like Teppo:

    Real-Time_Workflow_error_1

    After we click OK on the assign dialog, a Business Process Error dialog is presented, along with our status message text that explains why the operation cannot be allowed.

    Real-Time_Workflow_error_2

    The transaction is rolled back, which means the assignment never takes place and our project remains in the hands of a certified professional. CRM workflows save the day!

    Here’s a couple of considerations to keep in mind with the above example:

    • If I had set the workflow to run Before the assign event, I wouldn’t have received an error. That’s because we would have had a pre-image of the record to work with, in which the change of ownership would not yet have taken place. Having these options available in the workflow editor UI gives more flexibility for defining the business logic, but you should know at least a bit about the underlying Dynamics CRM event execution pipeline to make the most of them.
    • If I had simply clicked on the Project Manager (owner) lookup and changed the value, I wouldn’t have received an error in either case. That’s because from the platform’s perspective the assign event is different from the event of updating the owner lookup field. Also note that creating a new record for another user is not an assign event either, so you’ll want to expand the criteria of when the workflow rule is triggered to catch these.

    Stopping Unwanted Data Updates

    What kind of real life scenarios would then require the system to throw a Business Process Error at the user? Let’s think about a typical CRM implementation where the customer data is integrated with an ERP system. As long as you’re working with prospects that haven’t placed an order yet, there shouldn’t be too many limitations in place in CRM on how you can update the data. Once the account information is transferred to the ERP system for the purpose of order and invoice processing, the need for restricting certain operations on the account records will likely arise.

    Let’s assume that we’re identifying the ERP integrated accounts through the Account Number field on the CRM account entity. If the field contains data, then this is a record where updates need to be restricted. By leveraging the new CRM 2013 Business Rules we can configure the fields on the form to be disabled if an account number exist. But what about updates that are not performed as changes of form field values? This is an area the Business Rules can’t touch, but with real-time workflows we may be able to add custom business logic into CRM that would have traditionally required a .NET developer to write plug-ins for us.

    As an example, we’d like to ensure that no account records can be deactivated in CRM if they exist in the ERP system. The deactivation might take place through a data management operation like merging duplicate records, in which the master record is left in active status and the child record gets deactivated. We can’t directly trigger the workflow process from the clicking of the Merge button on the account view Command Bar, but we can set our business logic to be run on the status change event. Let us therefore build a new “Stop account merge” real-time workflow rule with the following criteria:

    CRM_2013_workflow_stop_account_merge

    We’re actually performing this after the deactivation has already taken place, but that doesn’t matter, because we’ll still be able to cancel the whole operation. We’ll look for any accounts that have gone through a status change event and are now in an Inactive state. If the account record has an account number, we’ll stop the workflow with status of Canceled and provide a message to the user explaining what are the proper steps to take in getting everything updated correctly both in the CRM and ERP systems.

    Let’s try this first on a single account record. When we click on the Deactivate button on the account form’s Command Bar, the Business Process Error dialog is presented to us, along with the message we defined in the workflow. No deactivation can take place, so the account is returned back to active status. More precisely, the account record status never changes, as can be verified from the audit history log (if enabled).

    CRM_2013_account_deactivate

    Great, now let’s move on to the Merge scenario and try to combine two active accounts with account numbers into a single account. We’ll select the accounts, click Merge, go through the Merge Records dialog, defy all the instructions given to us by the CRM key user of our organization and attempt to merge two separate ERP accounts in CRM. Once we hit the OK button for the merge to be performed, the Business Process Error dialog jumps to the rescue and stops the operation.

    CRM_2013_account_merge

    Hey, wait a second, why’s the text in the Business Process Error window different now? “ISV code aborted the operation”, what does that mean? Well, it seems that because we’re not actually performing the status change action directly on the record but rather leverage the built-in Merge Records dialog and its associated business logic for record deactivation, our status message text doesn’t  reach that screen. The event itself does “bubble up”, though, so stopping the status change also rolls back the entire transaction and none of the fields on the records being the targets of the merge operation change. That’s the important part, after all.

    Complementing Business Rules

    Let’s have a look at one more use case for the real-time workflow error messages before I let you get on with your browsing. The previous example covered an event that Business Rules weren’t able to control, due to the fact that they execute only on the entity form. In a CRM & ERP integration scenario you may however need to have the account record fields locked on more places than just the form. Remember that any updates the user would perform through other means, such as Excel export/re-import or a custom client app would not trigger the Business Rules that are essentially just client side scripts on the form. If you build this logic onto the server side as plug-ins or workflows, though, no one can perform an operation that would violate the rules (just ensure there’s always some supported way for performing the necessary updates & don’t block you integrations while creating these gatekeeper workflows).

    One built-in form where the Business Rules don’t run is the mobile form. Utilized in both the Mobile Express browser version as well as the mobile apps for Windows Phone, iPhone and Android, these forms offer a limited set of capabilities for reading, creating and updating records. While you can set a field on the mobile forms to be read-only, you can’t build any conditional logic to determine when the field should be locked.

    CRM_2013_account_name_edit

    CRM_2013_Mobile_Express_acount_editLet’s assume you want to allow people to quickly create and edit accounts through their mobile device, but you also want to lock down the account names on records that have been synchronized to the ERP system. To meet the first requirement you’ll need to leave the field on the form in an editable mode. To stop someone from accidentally overwriting the name of your biggest customer account with “Aasd,abhoignldfiiiiii” or other gibberish when fumbling around with CRM on their tiny little iPhone screens, you could create a real-time workflow to guard these fields from unwanted input. Have it run on the field change events, check whether it’s an ERP account with an account number and then cancel the event if necessary.

    Opening up the Mobile Express UI (just append the CRM organization URL with /m/ to access this version) and trying to edit the account name field now gives the same kind of notification as the full browser client. The Business Process Error dialog window doesn’t seem to have any mobile optimized version, but again it gets the basic job done by stopping the update. I didn’t test this on the Dynamics CRM mobile apps, but seeing how at least on Android the app is almost identical to the Mobile Express browser version I’d imagine the experience is similar there as well.

    OK, that’s the end of my experiments with real-time workflow process error messages for now. I’m sure that there will continue to be a need for more advanced solutions for controlling user data input that will involve hiding UI components through scripts or enforcing business logic through plug-ins, especially if the transaction volumes are expected to be high. The new workflow capabilities do however provide a quick way to configure custom error prompts and stop unwanted events when experimenting with the design options of your solutions and iterating your way towards the final production system.

  • Your Essential Toolkit for Microsoft Dynamics CRM

    You can do a lot with the configuration and customization toolkit that Microsoft Dynamics CRM offers. With the SDK and some lines of custom code, you can do almost anything. There in between lies the territory where the Dynamics CRM community is helping its members manage some of the commonly required tasks without the need for .NET developer resources. This is done through a wealth of wonderful, free tools that make it easier for anyone working with Dynamics CRM to access the power of the platform without getting their hands dirty in tweaking XML files or learning the right SDK calls.

    Many of the tools listed here are a permanent fixture I take along with me to any consulting gig, while some are new entrants to the list. If you’ve been actively reading up the posts on various popular CRM blogs, you may well recognize most of them. However, while I personally spend far too much time on social media channels, I realize that not everyone in the industry has the luxury for such a lifestyle and may have therefore missed out on some tools that could have saved them hours worth of work. Therefore, I decided to compile a “Best Of” post to highlight the 10 tools no CRM consultant should be without. (For anyone wanting to stay on top of the latest tools and solutions I come across, you can either subscribe to my Dynamics CRM Links RSS feed or follow the Surviving CRM page on Google+.)

    CRM 2011 User Settings Utility

    Download from CodePlex.

    When setting up new user accounts in your Dynamics CRM organization, wouldn’t it be nice if the system administrator could set their personal settings to match the policies of the organization as well as the likely preferences of the user in question? Things like Time Zone, Records per Page, Advanced Find mode, default home page etc. can be easily configured for users in bulk with the CRM 2011 User Settings Utility by Amreek Singh.

    CRM2011_User_Settings_Utility

    One particular pet peeve of mine related to the default configuration of Dynamics CRM is that new contact records are automatically created from tracked email sender or recipient addresses not found in the database. Well, with this tool you can stop the users from unintentionally populating your database with partially filled contact records not associated to their proper parent accounts by simply configuring the setting to “No” for all users. Beats having to send everyone instructions by email on how to check their CRM profile settings, doesn’t it?

    Universal Settings

    Download from Sonoma Partners website.

    It’s not only the user settings that may require you to pop the hood open on your CRM instance. There is a number of Organization Settings as well as Deployment Settings that can be used to either overcome limitations or alter the default behavior of Dynamics CRM. For example, if you’d like to be able to export all of your contacts records from CRM to Excel and not just the first 10,000 then you’ll be happy to know that changing the MaxRecordsForExportToExcel parameter is a breeze with Universal Settings, no matter if you have an on-premises or CRM Online environment.

    UniversalSettings

    Another handy limit you can adjust with the tool is AggregateQueryRecordLimit, which will allow your charts to summarize more than 50,000 records at a time, instead of seeing “the maximum record limit is exceeded” errors. Also very handy if you wish to work with more than 50,000 marketing list members in your campaign target group. Unfortunately this tweak is not available for CRM Online, though, as the setting resides in the deployment table rather than the organization table, which is the only one you can update in the cloud.

    XrmToolbox

    Download from CodePlex.

    We’re now stepping into the world of “Mr. CRM Tools” himself, a.k.a. Tanguy Touzard. His awesome Toolbox for Dynamics CRM 2011 is a collection of the various tools developed over the years to help make Dynamics CRM administration and customization more efficient and enjoyable. By downloading the Toolbox you’ll get a number of great tools, but just to ensure you understand why you need them, let me give a quick intro to my favorite ones.

    Sitemap editor

    Adjusting the CRM main page navigation (a.k.a. sitemap) is something that you should always perform after you’ve determined what are the entities your different user groups (sales, marketing, etc.) will need to access and what is the logical arrangement of them in the navigation. Trust me, the right answer is not “the order in which the entities were created” nor “alphabetical”. There’s a number of free sitemap editor tools out there, but since XrmToolbox is such a powerhouse, it makes a lot of sense to use the the same tool that you’ll be using for other tasks in the same organization, as you’ll only need to configure the connection parameters once.

    Sitemap_editor

    Re-arrange, add, hide, group, rename, do basically whatever you want with the CRM menus with this editor without ever seeing a trace of the solution XML file contents.

    Easy Translator

    Easy_translatorThe latest addition to XrmToolbox is something every CRM admin from a non-English speaking country can surely appreciate. Since most of us still prefer to use the English base language setting in Dynamics CRM due to the awkward terminology of our native language translations in the customization UI (and any potential technical compatibility quirks that come with it), working with the “export/import labels for translation” process is all too familiar to us. Hunting down those strings in the unstructured output file isn’t very pleasant, which is where Easy Translator comes in handy. You’ll get a nicely arranged Excel with just the types of labels you’ve selected for export, which reduces the amount of trial & error in translating fields, values and form labels to the language of your choice. (more…)