Category: Tips

  • Your Interaction Network in Dynamics CRM

    Your Interaction Network in Dynamics CRM

    One of my posts that seems to remain in high demand, based on the site visitor analytics, is Advanced Queries with Advanced Find. Written over two years ago, people still tend to read it far more often than the newer posts dealing with the latest trends around Dynamics CRM or instructions on how to leverage other platform features like workflows and Business Process Flows. Thinking about the potential audience size, it’s of course understandable that a feature accessible to all CRM users will be much more popular than process configuration tools or the Dynamics product roadmap.

    AFAlthough very few updates have been done on the Advanced Find functionality during the 10 years I’ve been using Dynamics CRM, it’s arguably still a real killer feature of the platform, at least when comparing it to the query capabilities of many similar business applications. The fact that you’re able to reference pretty much any related record in your query criteria (and in the CRM data model, absolutely everything is related) means that the tool can be used for building the most complex target group definitions for your marketing campaigns, for example, based on behavioral data stored many relationships away. You only have to use another Microsoft application to understand how powerful such a tool can be in the right hands.

    It never hurts to have a good understanding of the CRM data model of your organization when launching Advanced Find to build some queries, since AF is a world of abundance when it comes to the available options to select from. Usually the relationships between records are something you can figure out from the end user UI if you spend a moment thinking about it – although with the “flat” design of CRM 2013+ menus and navigation structures, the front end ain’t as hierarchical in nature as the old popup-heavy UI used to be, thus sometimes leading you astray with the underlying data model. In some cases, though, Advanced Find will allow you to perform queries on entities that are completely invisible to the CRM end user. In this post we’ll take a look at one such entity, the activity party, and explore ways in which we can use it for providing the CRM users information on who they are interacting with.

    Ain’t No Party Like The Activity Party…

    ActivityParty_Appointment…’Cause in the Activity Party everybody’s connected! OK, so what exactly is this “party” thing then? In the CRM user interface we have activities, which are divided into a number of different types, like email, appointment, phone call, letter, fax (everyone’s favorite default entity, right?) and potentially a selection of custom activity entities for non-standard communication channels like SMS or business specific record types for handling assignments, approvals and these types of work items. Each activity type shares a number of common fields that can be found from the entity called “activity”, which is what allows CRM to show this mixed bag of apples, oranges and pineapples in a single list of fruit activities related to a business record like the customer account.

    When we add people into an activity like a meeting invitation (remember: appointments are always invitations now in the server-side sync world, so be careful when including customer contacts there), CRM is not just populating a lookup field on the activity entity with the GUIDs of all the related users, contacts and other resources. What happens behind the scenes is that each of these related records will result in a new activity party record being created. This is an entity that you will not see in the CRM customization UI if you open the default solution. You can read about it in the SDK, or install a tool like the Metadata Browser (found inside the downloadable SDK package) and have a look at its contents from the live system, as we see below.

    ActivityParty_Metadata

    People who have been tasked to build SSRS reports that deal with activity records will have surely run into the ActivityParty table/view. If you’re interested in learning more about how the data is created and stored into the SQL database, go and read this great investigation by CRM MVP Aileen Gusni. If, on the other hand, you’d rather not spend too much time in Visual Studio / SQL Server Data Tools building reports but rather want to see how to leverage activity parties in Advanced Find, then this is the right article you’re reading right here.

    View of “Activities Involving Me”

    While activity parties are not accessible as a configurable entity in CRM (because ultimately they’re not), luckily they do exist in the Advanced Find UI. The first scenario in which we can take advantage of this capability is in building a view of activities that uses some criteria that’s not directly available on the activity record itself. Out of the box, CRM provides views like “My Activities” that show the records in which the current user is the owner (and which are open, even though the name of that default view is a bit misleading). Sure, it’s important to understand what’s on your To Do list right now, but sometimes it is beneficial to be able to reflect back a bit and see also what has happened in the past, to understand what you’ve spent your time on and who have you interacted with. For this, we’ll create a brand new view called “Activities Involving Me”.

    (more…)

  • Tracking Pipeline Development Over Time in CRM 2015

    Tracking Pipeline Development Over Time in CRM 2015

    We’ve come to part 3/3 in the Smarter Sales Process article trilogy. In the earlier posts we talked about customizing the lead qualification process and using calculated fields for opportunity estimated revenue, to get more out of Dynamics CRM 2015 than what the standard sales related functionality offers. To close things off, let’s have a look at how we can gain more insight into the data in our sales opportunity pipeline and particularly how it has developed over a period of time.

    Capture the Sales Pipeline Trend

    With the data that Dynamics CRM collects about sales opportunities we can easily draw charts about how many deals were won or lost at any given time, presenting these as a monthly trend of both estimated and actual revenue. It’s also very simple to visualize the current contents of our sales pipeline by looking at the open opportunity records via standard visualizations like the… well, pipeline chart, obviously!

    What we can’t do quite so easily is to present how the sales pipeline has developed over time. For example, has the number of opportunities in a particular stage of the sales process gone up/down, or how the total estimated revenue from open opportunities is developing. An average CRM user may not understand why such a visualization wouldn’t be included in the application by default, but for a system customizer that knows the data model and behavior of Dynamics CRM this should be fairly obvious. The fundamental difference between closed opportunities and open opportunities is that for the former we have a permanent record of when they were closed and with what values, whereas the records that are currently in an open status represent transient data. It will change over time, based on the future actions that CRM users will take.

    So, what’s the problem with such data? The fact that an open opportunity may have been open last week or even ten weeks ago makes it impossible for us to draw a chart that would show a weekly number of records, since only a single record exists in the database, even though it might need to appear in the bar for each week in a chart showing the size of the pipeline on a weekly level. While technically we would have the information needed to project the number of opportunities that have been open at a given time by looking at their creation date, this would be a more complex exercise than what the ASP.NET charts in Dynamics CRM allow us to draw (although I wouldn’t be surprised if CRM Chart Guy would prove me wrong on this one).

    At the end of the day CRM is an operational system focused on managing individual records and transactions, which means it doesn’t bother archiving copies of records in their historical state. Sure, we have the audit log that will keep a record of the individual changes to tracked fields, but that’s data which isn’t accessible for reporting. But the question to ask is: if we wanted to capture such historical data for our analysis purposes, could we do that with Dynamics CRM? Sure we could! In fact, already back in 2008 when CRM didn’t yet have a built-in auditing capability, CRM MVP Guy Riddle showed us how the use of custom entities and workflows allowed us to build our very own audit log feature to capture changes for record field values.

    CRM_opportunity_count_by_week_and_stage

    Sure, our use case here is a bit different, since we’re not looking to only capture entries on when a record changes. To provide us visibility into how the sales pipeline has developed over time, we would need to capture a snapshot of the pipeline status at predetermined intervals.

    Scheduling Snapshots of CRM Data

    One of my favorite features in CRM 2015 version is Rollup Fields, which I’ve already covered in a number of earlier posts on this blog (including the gotchas you need to be aware of). This feature also comes in handy if we want to build a custom snapshot entity to store the count or sum of records related to it. In this scenario for monitoring sales pipeline development, which I presented in my MSDynamicsWorld.com webcast “A Non-Developer’s Guide to Smarter Sales Processes in Microsoft Dynamics CRM 2015”, what we’ll do is make a 1:N relationship between our custom Snapshot entity and the opportunity entity. This in turn will allow us to create Rollup Fields that will summarize the count and revenue of the related opportunities onto the Snapshot record. By having a snapshot per each stage of our sales process, we will get the attributes needed for drawing the kind of chart shown above, to visualize the trend of opportunity count and estimated revenue development per week.

    The detailed steps for the required customizations can be found from the following SlideShare presentation:

    The one missing ingredient that we still need to think about is how to automate the capture of these snapshots. What Dynamics CRM still doesn’t offer out-of-the-box is the ability to schedule recurring workflow processes in an easy way, to perform an automated task every X days. Luckily there are workarounds for scheduling such bulk data processing tasks with using nothing but the CRM platform, and one of the best solution’s I’ve come across is the Scheduling recurring Dynamics CRM workflows with FetchXML solution from Lucas Alexander. I’ve already shown you how to use this solution for monitoring Rollup Field Values with workflows and the same logic can be applied in this scenario, too. Only this time we don’t send a weekly email blast to CRM users, rather we’ll just create new snapshot records to store the opportunity count and total estimated revenue per sales stage.

    CRM_scheduled_process_opportunity_snapshot

    Alright, that concludes my Smarter Sales Process for CRM 2015 series, at least for now. As mentioned at the start, do check out part 1 and part 2, as well as the YouTube recording of the live demos if you’re interested for more details on the topic. Hopefully these examples have given you some new ideas on what kind of solutions you can build with the Dynamics CRM 2015 customization tools. If you’ve got any thoughts on what kind of no-code customization scenarios you’d be interested in seeing in the Surviving CRM blog in the future, please feel free to leave a comment!

  • Using CRM 2015 Calculated Fields for Opportunity Estimated Revenue

    Using CRM 2015 Calculated Fields for Opportunity Estimated Revenue

    It’s time for part 2 in the Smarter Sales Process article trilogy. As described in my previous blog post about lead qualification process customization, this content is taken from my MSDynamicsWorld.com webcast titled “A Non-Developer’s Guide to Smarter Sales Processes in Microsoft Dynamics CRM 2015“. After having adjusted the lead to opportunity process to better suit our needs, we’ll next have a look at how the data managed in the opportunity stage could be more easily entered and maintained by leveraging the no-code customization tools available in Dynamics CRM.

    Introduction to Calculated Fields

    As you should have noticed by now, the CRM 2015 release added the possibility for defining two new “complex” field types in addition to the traditional “simple” fields. Rollup fields is something I’ve covered in more detail in an earlier blog post, so this time we’ll be working with the other type, which is the calculated fields. Essentially these are the types of fields where you don’t directly insert a value in CRM, but rather the field value is calculated from one or more other fields in the system, based on the formula and conditions you specify in the calculated field definition editor found from the field’s properties in the CRM customization menus.

    How calculated fields differ from rollup fields is that with them we’re always working on the current record, whereas rollup fields retrieve data from related records. Well, actually that’s not entirely true, since a calculated field can also reference a value from a related parental record in its formula. A more accurate description could therefore be that calculated fields can access data from the “1” side of the 1:N one-to-many relationship, whereas rollup fields are the tool for retrieving data from the “N” side of the logical data model in our CRM organization.

    Another aspect that the system customizer must be aware of before starting to leverage these new tools for building CRM 2015 solutions is how and when the field values are calculated. As demonstrated in my post “CRM 2015 Rollup Fields: The Gotchas“, the data shown in rollup fields may be up to 30 minutes old, since these are updated based on an asynchronous job (unless you apply the workaround described in that blog post). Once they are updated, though, the values are persisted in the database. Calculated fields work in the exact opposite way, meaning they are calculated in real-time, but the data is not actually stored in the CRM database. While the latter part of that sentence might sound strange at first, it simply means that the CRM platform performs the calculation any time the specific calculated field is needed. This includes opening a form that contains the field, browsing a view with such columns, accessing a dashboard with charts referencing calculated fields, making SDK calls for retrieving this data and so on.

    To familiarize yourself with the details of these features, have a look at the TechNet article Define Calculated Fields. Or if you’re in a hurry, spend 5 minutes watching this YouTube video from the CRM product team, to see how what the new fields look like in the customization UI.

    Applying Calculated Fields on Revenue Estimation

    The scenario that I chose for the Smarter Sales Process series deals with the way we determine an estimated value for an opportunity record in Dynamics CRM. By default, you have the option of either entering a lump sum into the Est. Revenue field of an opportunity record, or creating individual opportunity product records as line items that have a specific revenue value. This is what the bit field IsRevenueSystemCalculated is all about, with its options of “User Provided” or “System Calculated”. Since many organizations using Dynamics CRM don’t actually bother maintaining the detailed product catalog and price details in corresponding CRM records (at least not without a custom integration being built to sync the data from other systems), the “User Provided” option is quite often used for recording just the total estimated revenue value for the opportunity. What this means in practice is that the sales people end up using their own Excels to calculate the various components from which the revenue is generated and just entering the end result into CRM. If any parameter in the equation changes, it’s back to updating your Excels, then CRM again. Oh joy.

    Could there be some middle ground between taking just a single figure from an external Excel sheet and having a full blown product & price catalog maintenance process for CRM? If the products and services you’re selling consist of a limited set of key revenue components that are typically included in each quotation you make, then exploring the possibilities of creating custom fields for these components directly onto the opportunity record might well be in order. While these will not provide the high granularity data of having opportunity product line items with links to the related product record, the data entry and maintenance experience is probably going to be a lot easier for you to sell to the CRM end users. (After all, we’re talking about sales people here, who are the toughest crowd you’ll ever need to please with your CRM system functionality.)

    CRM_Opportunity_Estimated_Revenue_Calculated_Fields

    In this example scenario we’re selling CRM consulting projects that have three common revenue categories: consulting revenue, license revenue and “other” revenue. The total value of each area is calculated via a specific formula, after which each area specific revenue is summed up into the Total Amount field. As you’ve probably guessed by now, this is achieved by using the CRM 2015 calculated fields feature. Compared to adding the line items one by one, configuring unit prices and other variables, the data entry process is considerably faster, since all the user needs to do is tab through the relevant fields on a single form and enter values where necessary. You can catch a quick glimpse of the live opportunity form in this YouTube recording of the webcast.

    For a detailed explanation of how this type of functionality can be configured in Dynamics CRM, have a look at the following slides: Smarter Sales Process in Dynamics CRM 2015 – Part 2: Revenue Estimation.

    A Few “Gotchas” on Calculated Fields

    If you’ve implemented a similar custom opportunity form in the past by using Javascript to perform the calculations, then you should be aware that the native calculated fields in Dynamics CRM don’t offer exactly the same user experience as custom scripts do. The reason is that the calculation logic is executed whenever the fields referenced in the formula are retrieved from the CRM, meaning not before you’ve submitted the updated source field values into the database. So, the moment you change a field value (let’s say “consulting hours” in our example”) and click/tab to the next field, a client-side script would be able to recalculate the fields instantly, triggered by the onChange event of the field. A calculated field will just sit there waiting for the source data to be saved to CRM first, either via the auto-save feature every 30 seconds or the user explicitly clicking on the save icon in the bottom right corner of the form.

    Considering that with CRM 2013 we received the Business Rules feature that acts in practice the same way as a custom script (meaning it’s executed on the client side), this may seem like a slight setback in the level of application UI responsiveness for Dynamics CRM. Knowing that there are also some calculation capabilities available with Business Rules, you might be wondering if this feature could be used instead of calculated fields, to deliver an even better user experience. Well, based on my personal experience, if you try to build a very complex chain of calculations by using Business Rules, you’ll soon find yourself in a world of pain trying to figure out why the events don’t always trigger the way you want them to, how to handle resetting field values and so on. Although I haven’t yet used the calculated fields feature in as many real life scenarios as Business Rules, at least I haven’t run into similar problems in ensuring validity of the calculations performed with them, so my recommendation would be to always opt for calculated fields whenever you need to… calculate the value of a field (ever get the feeling that us consultants just state the obvious things?).

    Another thing to be aware of when it comes to calculated fields and Business Rules is that the two don’t mix. More specifically, a Business Rule cannot reference a calculated field, so you cannot grab the results of the calculation and use them in a subsequent business logic implemented via a Business Rule. Luckily, you can still access the calculated field values in a workflow process, which is the workaround that I’ve used in my aforementioned presentation.

    During the webcast, there was also a very good questions presented on whether there are some limitations on how many calculated fields you can use on a single entity. Based on the official documentation, there doesn’t seem to be any hard limit on the number of calculated fields you can create, but you cannot include more than 10 calculated fields into a single view (or chart), which could potentially be reached if creating a highly complex calculation scenario and a summary view to export the resulting data out of CRM.

    As always, the responsibility on system performance impact ultimately lies on the system customizer, even if the solution is created just via clicking the CRM configuration options instead of writing custom code. As the no-code customization tools get more advanced with every release of Dynamics CRM, it’s becoming increasingly important also for people in the business analyst role to have a basic understanding of how the underlying application platform operates. I want to highlight a couple of recent whitepapers that Microsoft has released around the solution design and performance topic, which should give you plenty of food for thought, whether you’re approaching Dynamics CRM from a developer point of view or if you’re an analyst that’s aspiring to design more complex CRM solutions:

  • Customizing Lead Qualification Process in CRM 2015

    Customizing Lead Qualification Process in CRM 2015

    This is the first part in an article series where I’ll be presenting a few customization tips & tricks that you can use in Microsoft Dynamics CRM 2015 to enhance the functionality used in a typical sales process. The content was first shown in my live webcast on MSDynamicsWorld.com on May 6th: “A Non-Developer’s Guide to Smarter Sales Processes in Microsoft Dynamics CRM 2015.” As promised during the webcast, I’ll be releasing all the slides here on my blog, but since there was a lot of details to go through in the 1h session, it will be split into three separate articles, to improve the accessibility to this information for those who didn’t attend the live webcast.

    The overarching theme of this series is to show you how the creative combination of the various customization tools available in Dynamics CRM 2015 can be used for building whole new functionality into the application – without having to write any custom code. The emphasis is on the word combination, since very often you’ll need to use several different pieces of the platform’s customization tools to achieve the end result. This isn’t something that you can easily learn just by reading the official product documentation that typically focuses on the introduction of a single feature at a time. With the examples in this article series I hope to demonstrate what these combinations could look like, in the context of customizing the standard application behavior in the sales process.

    MSDynamicsWorld_Smarter_Sales_Process_scenarios

    The techniques are by no means exclusive to the sales area of Dynamics CRM. Any process that you manage with our CRM/XRM application can surely benefit from the type of custom functionality that you can build via Business Process Flows, Real-time Workflows, Business Rules, Calculated Fields and Rollup Fields. The absolutely best way to gain an understanding of what you can achieve with the point & click customization tools in Dynamics CRM is to experiment with the tools in a sandbox environment, so I encourage you to go and try out these scenarios in an actual working CRM system. (Why not spin up a new CRM Online trial org and also get access to all the new CRM Online 2015 Update 1 goodies while at it?)

    What’s Wrong with CRM 2015 Lead Qualification?

    Those of you that have been working with Dynamics CRM for more than just a couple of years will probably remember how the things used to work before CRM 2013. When clicking on the Qualify button on a lead record, the user was presented with a dialog that allowed them to choose whether a new account, contact and opportunity record should be created from this lead. In the new world of Business Process Flows and no-popup UI of CRM 2013 (and CRM 2015), such options are no longer presented to the user. While this makes for a smooth user experience in general, it creates severe conflicts with many real life business processes of companies who either A) don’t use opportunities or B) don’t want to directly convert each lead into an opportunity. There are lots of suggestions on MS Connect (registration required, see here) to restore the ability for users to select not to create an opportunity from a qualified lead, but so far we haven’t seen any changes in the product to accommodate this.

    CRM_Lead_Qualification_Dialog

    So, if CRM wants to create opportunities but the user doesn’t, what could a mere system customizer do, without any knowledge of how to write plugins or scripts to develop new functionality by using the CRM SDK? Well, I’ve come up with a reasonably good workaround that uses the following solution components to establish a true user driven lead qualification process:

    • Branching Business Process Flow (BPF) to show stages that don’t take the user to the opportunity entity
    • Real-time Workflow to hand the lead status change and record creation instead of the built-in, non-configurable business logic of Dynamics CRM
    • Business Rules to conditionally show/hide fields for account/contact details on the form
    • Quick View Forms to present the records created from lead qualification process on the lead form after it’s closed

    You can find the detailed description of how I’ve configured each components from the below presentation:

    (For those of you who are not reading this article directly on survivingcrm.com and can’t see the embedded SlideShare presentation, click this link to access it.)

    I hope that this example has given you some ideas on how the lead management process and related Dynamics CRM functionality could be further developed in your own CRM organization. Stay tuned for part two of this Smarter Sales Process series, where we’ll be moving to the opportunity record and exploring how the estimated revenue information can more easily be managed by using the Calculated Fields feature introduced in Microsoft Dynamics CRM 2015 release. If you simply can’t wait for it or want to see the lead qualification process in action, then the webcast recording is available on YouTube already today.

  • Monitoring Rollup Field Values with Workflows

    Monitoring Rollup Field Values with Workflows

    In an earlier post I demonstrated how you could leverage the new Rollup Fields feature of Dynamics CRM 2015 to summarize the behavior of your customers and produce interesting metrics that could be used for targeting your sales activities towards the most active individuals who have reacted to your email and website content. The example included using data collected by ClickDimensions on the clicks on email marketing message links and page views on sites that contain the visitor tracking script. With the help of Rollup Fields and this marketing automation data stored directly into Dynamics CRM database under the contact records we were able to add the following custom fields onto our contact entity form:

    • Latest Email Link Click
    • Total Number of Link Clicks
    • Latest Page View
    • Total Number of Page Views

    While this allowed us to create a nice, sorted view of the contacts who’ve been interacting with our online content most recently, this information is still just data sitting in the CRM system, waiting for the users to go and discover it. Wouldn’t it be great if we could actually build an automated business process around it and make sure that the owners of these contacts who are clicking the links and visiting our website would be notified about these events? Sounds like something that a CRM workflow could help us with, right?

    CRM_2015_rollup_field_Clicks_5

    Unfortunately there are a few limitations when it comes to the new Rollup Fields in CRM 2015, as we discovered in my previous article. For example, if we would like to trigger a workflow process instance whenever the number of Link Clicks goes above a certain threshold, this isn’t something we can do directly by tapping onto the onChange event of the Total Number of Link Clicks field, because Rollup Fields cannot be used to trigger a workflow.

    Ok, what if we lower our expectations a bit and don’t even attempt to perform these actions in real-time for each event? It might be perfectly acceptable from a business perspective to have a process run once every night, inspect which contacts had clicked on the tracked links and then send out notifications to the record owners in one go. Surely that’s something Dynamics CRM can do, right? Well, let’s see if we could put together a solution like this.

    Batch Processing CRM Data with Workflows

    It’s quite a common requirement to perform checks or updates to CRM records based on a predetermined schedule. Although you can use workflow processes to be triggered on an event that takes place on CRM records (as long as it’s not on a special attribute like a Rollup Field), there isn’t actually any ready-made feature available in the CRM platform that would allow you to schedule the workflows to run every X hours, every night, once a week etc.

    The traditional approach for meeting such requirements for scheduled updates would have been to develop a small custom service to run on the CRM server machine. If you had access to other systems with interfaces to CRM like SQL Server Integration Services (SSIS) then these could naturally be also leveraged here. In the brave new cloud era where the number of Windows servers at your disposal for running these type of applications is rapidly decreasing it’s sometimes challenging to find a place where such schedulers could be deployed to, for performing small batch jobs that your CRM business processes would require. Wouldn’t it be convenient if you could build all of this by using just CRM Online and nothing more?

    Get ready for the good news: yes, you can schedule a recurring workflow to handle batch updates within Dynamics CRM, no external servers needed. The one thing you need, though, is a clever little custom workflow activity to extend the standard features of the CRM workflow engine. In this example we’ll use the Scheduling recurring Dynamics CRM workflows with FetchXML solution developed by Lucas Alexander. What this solution does is it gives us the possibility to:

    • Determine a query criteria for the bulk job
    • Schedule this job to be run hourly/daily/weekly
    • Run our own workflow process for all records returned by the query

    CRM_schedule_recurring_workflows_Lucas_Alexander

    The above diagram by Lucas outlines the logic behind the solution, but you really should go and read his blog post on the details of this approach, or check out the source code for the custom workflow activity on MSDN code gallery if you really want to dig deeper into the topic. For the purpose of today’s scenario, I’ll show you how I’ve used the solution in conjunction with the aforementioned Rollup Fields.

    Sending Out Notification Emails Based on Rollup Field Data

    In my example I’ve determined that it’s the Latest Page View datetime field on a contact that should be driving the business process. Once a week I would like to notify the owners of customer contact records if the contact has visited our website during the last 7 days. Turning this into a query criteria, it would mean that during the time of each batch processing I’d want to retrieve all contacts where the Rollup Field for Latest Page View contains a value greater than today minus 7 days.

    I will need to turn that query definition into a language that Dynamics CRM understands, and that is FetchXML. Sounds a bit tricky, eh? Lucky for us, CRM comes with a nifty lil’ FetchXML generator called Advanced Find, which I’m sure you’re already familiar with. All we need to do is find Advanced Find, specify the aforementioned query criteria for the contact entity and then click the “Download Fetch XML” button in the ribbon to grab the XML text into Notepad.

    CRM_AdvancedFind_FetchXML

    Next we should think about what action we want to perform on the contacts who match the query criteria. In this scenario it will be the sending of an email message to the owner of the contact. It only needs to be available as an on-demand process and there isn’t even a requirement to have any query criteria enforced here, but I added the 7 day rule here as well, just in case I end up using the same process in some other scenario.

    CRM_page_view_notification_workflow

    The final step is to create a record for the new Scheduled Process entity, which has been added to CRM in the solution packaged developed by Lucas. On this form I’ll first give a descriptive name to the Scheduled Process and then define it to be related to the contact entity. In the Workflow lookup field I’ll pick the workflow process you see above, and for the Query field I’ll paste in the FetchXML we grabbed from our Advanced Find.

    CRM_scheduled_process_page_view_small

    All that’s left for us to do is setting the actual schedule for this process. The weekly option in the dropdown menu suits our purpose best in this scenario. By adjusting the Next Run Date I can configure the email notifications to go out in the morning, so that they reach the inbox at an optimal time.

    CRM_notification_website_visit

    Alright, that concludes our scenario for using CRM 2015 Rollup Fields together with workflow processes to deliver actionable insights to our CRM users on how customers are responding to our marketing activities. What I personally find very interesting in this example is the ability to take a piece of existing data that’s sitting inside our CRM database and first turn it into a metric that’s easily viewable in the CRM UI, then further amplify its business impact by configuring conditional processes to deliver it as a notification to the user who should become aware of it.

    None of this required a huge technical development effort or investments into separate reporting systems. All we needed was to take a new feature that was added to the Dynamics CRM platform as a part of the 2015 version rollout (this being a CRM Online environment there wasn’t even an upgrade project to worry about), combine that with an excellent open source enhancement to the platform’s workflow functionality, then just design a solution that delivers new business value from existing data. If you look at your own Dynamics CRM system and the data that’s being collected into it as a part of your business processes, then I’m pretty sure you could also identify potential use cases for similar type of enhancements, built with CRM’s ever evolving process automation toolkit.

  • CRM Navigation Hacking with Bookmarks

    CRM Navigation Hacking with Bookmarks

    When you spend your days working closely with an application like Dynamics CRM, such as when customizing or developing solutions for your customers, your mind will often times be working much faster than the application. You know exactly which feature you want to access, but if you need to navigate through several levels of menu hierarchies to get there, the process may be too slow to keep up with your train of thought, making it hard to concentrate on the actual task at hand.

    My personal strategy for reducing the cognitive burden involved with navigating inside Dynamics CRM has been the use of smart bookmarks. Here’s some tips on how I’ve set up my current working environment. If you have any similar CRM productivity tips of your own, please do share them in the comments section below.

    Launching New Tabs from “Quick Nav”

    While piling up a mountain of open browser tabs may not be great for your productivity either, the cost of moving between tabs is still lower than constant in-app navigation between menus. When working with CRM customizations, I always tend to have the end user content in one tab (views or record detail forms) and the Solutions view on the other one, so that I can quickly access the component I want to modify and validate the results with an F5 on the other tab.

    Dynamics CRM 2013 and beyond unfortunately don’t support the standard convention of right-clicking on menus and opening them up in a new browser window. Nothing stops you from opening CRM in a second tab and working with the settings via it, but this means you always have to start from the first page and navigate back to where you wanted to go. To speed things up a bit, I keep a “Quick Nav” available menu in all my browsers, created as a folder in the favorites/bookmarks bar that I also keep open at all times.

    CRM_QuickNav_menu

    So where exactly do those bookmarks lead to? A specific menu in a certain CRM organization? Nope, those are generic bookmarks that apply to the currently open CRM organization. They work in any CRM 2013 or CRM 2015 environment, on-prem or Online. You see, they are not actual bookmarks with a static URL pointing to a resource somewhere, rather they are bookmarklets that contain a short piece of JavaScript. (more…)

  • Who Is The Customer in Your CRM? (Podcast)

    Recently I was invited to make my second appearance on the CRM Rocks podcast series, hosted by Markus Erlandsson. The first episode we did back in fall last year was focused on “what’s new in Microsoft Dynamics CRM 2013”, which was certainly a timely topic back then. This time we decided to discuss on a theme that was less focused on the CRM application functionality or a specific version of it. On our agenda was the question “who is the customer”?

    It might seem like not such a complex question to answer at first. After all, if we are deploying or developing solutions for customer relationship management then surely there must be a clear understanding of what exactly we need to be managing with the system, right? Well, as with most things related to designing a CRM solution, there isn’t a single right answer, but there are many good questions instead! To help anyone who’s starting their journey towards implementing a CRM system for their company and wondering what questions should be asked from the business and process owners, I’ve listed some of these topics into the following presentation available on SlideShare:

    Our discussion in the podcast covers five major aspects of the CRM solution design fundamentals:

    • Who is your customer?
    • B2B customer modelling
    • Segmenting your customers
    • The role of non-customers in CRM
    • Why Social CRM is the new CRM

    While some of the podcast content is of course specific to the application platform that I have the most experience of working with (can you guess which one?), I hope and believe that much of the guidance would also apply to any modern CRM system you might be deploying. So, please have a look at the slides above, and if you feel like the contents is relevant to the business problems that you hope to solve with customer relationship management technology, proceed to listening to the full CRM Rocks podcast.

  • 10 Tips for Designing a Great User Experience in Dynamics CRM

    Last week I had the privilege to talk at the Dynamics CRM Finland User Group meeting in Helsinki (quick recap available in Finnish here). When planning on what topic to choose for my presentation, I tried to think of something that would appeal to a wide audience of CRM users – both experienced consultants as well as key users who might still be relatively new to the product.

    The common denominator for the group was, as the name suggest, that we’re all CRM users in one way or another. In this role we interact with the software in a variety of different ways, most likely several times during the course of a typical working day. As information workers, systems like CRM are our tools to get the job done. How effectively we succeed in this is largely affected by how much cognitive effort is needed to use these tools to shape the expected output.

    So, I decided to talk about the many ways how we can sharpen our saws when it comes to Dynamics CRM. While every CRM environment is ultimately different from one another, due to the business processes we manage with it, the systems it integrates to, the user groups working with the application and so on, I believe there are still general design guidelines that apply to basically any organization using Microsoft Dynamics CRM. My presentation, “10 Tips for Designing a Great User Experience in Dynamics CRM“, introduces many of these guidelines that I personally try to follow when designing CRM solutions for customers. You can view the embedded presentation below, or if the content is not showing, then go and have a look at it on SlideShare.

    While UX has always been an important piece of the puzzle when trying to convince business users that using a CRM system can actually deliver tangible benefits to them, rather than just serve as a management tool for keeping track of what the employees are doing, the launch of the Dynamics CRM 2013 version has really heightened the importance of designing solutions with a polished user experience. This is due to the fact that the refreshed user interface and new customization points available in the UI can be leveraged to deliver a much more usable business application than the CRM systems of the past. But: you also need to plan the flow of user interactions with much more attention to detail, because sloppy customizations will now stick out like a sore thumb.

    The good news is that many of the new details in CRM 2013 (and CRM 2015, too) are easy to configure once you know the role of each platform component. You can do so much these days without writing a single line of custom code that the system customizer can easily have his or her plate full of CRM enhancement ideas to implement without ever consulting a .NET developer. That’s why it’s also good to think in advance how to prioritize the areas into which you invest your efforts. This Top 10 list of mine provides one example of such a tool, to help in identifying the low hanging fruit when it comes to making your CRM users happier and more productive with the system. If you have any topics on your mind that I forgot to include on my list, be sure to leave a comment below!

    10_CRM_UX_tips

    Oh, one more thing: if you’re a Microsoft Dynamics CRM user in Finland and would be interested in networking with other fellow CRM professionals, I’m glad to announce that there’s now a new Yammer network available for you: Dynamics CRM Finland User Group. Whether you’re from a customer or partner organization, please feel free to sign up for this network and come join the planning for future events and other ways to share Dynamics CRM knowledge and experiences with peers. Tervetuloa!

  • Time Travel with Workflows: Accessing “Before” and “After” Values

    Time Travel with Workflows: Accessing “Before” and “After” Values

    Dynamics CRM has had a built-in auditing feature since the 2011 version, which provides a really handy tool for situations where someone needs to investigate the changes that have taken place on field values of a specific record. By default auditing is not enabled, but I recommend you to seriously consider enabling it for all business critical entities like accounts and contacts, since without it there’s not much to go by if you ever need to track down any intentional or unintentional updates made to your CRM data.

    CRM_workflow_audit_1

    Auditing is a great tool for capturing the “fire hose” of data updates that are taking place in CRM. However, since the audit data is not stored in actual CRM records but rather in a denormalized state inside the audit database tables, it’s not accessible for any type of reporting or business process logic. If you know what record to look for, the related Audit menu will give you the information. If you are an administrator and have access to the Audit Summary View, you can also use filters to narrow down the audit data stream and hunt down the events that are relevant to your investigation. Very useful for resolving issues in the data, but not so practical for simply staying informed about updates that are of interest to your role in the organization.

    Workflow processes can also be used for tracking specific changes made on the CRM records, just by setting the workflow to start when a particular field or a set of fields change. You can then perform any notification action you see appropriate, such as sending an email, creating an Activity Feed post, adding a note, appending a description field etc. Almost like auditing, but on a much more granular level, and also something that you can report on if necessary. One limitation compared to auditing, though, is that you can only see the new value of each field but not the previous one. So, you can’t produce a similar view that auditing provides, with the old and new values side by side.

    Or can you? With the launch of the CRM 2013 version we gained a whole new category of workflow processes, called real-time workflows. These behave much in the same way as custom plugins, as they are executed synchronously as part of the event pipeline of the CRM platform rather than via the asynchronous service that the traditional workflows use. The extra benefit we gain from this, aside from the fact that the workflow logic is executed immediately, is that we now also have the ability to choose whether the real-time workflow should be started before or after the event. This allows us to actually read the data that was in a field before the update took place. Sounds like a cool little feature? Well why don’t we take it our for a spin then and see what we can achieve with it.

    Tracking Account Name Changes

    Let’s consider a scenario where we would be interested in tracking the changes performed on the account name field. We have decided to leverage the Activity Feeds feature to post a message on the record wall every time an existing account has its name field updated. As a part of this post, we need to provide both the old name and the new name, so that the users can easily associate this particular account as a customer they’ve previously done business with under a different name.

    Since we need a place to store the old name of the account for the purposes of formulating the post’s content, first we’ll add a new custom text field for the account entity, called “Old Name”. Then we’ll open up the workflow editor and create a new real-time workflow process for the account entity, called “Account Name Change: Store Old Name”. The important part here is that we’ll set this workflow to be run when “Record fields change” with a box ticked for the “Account Name” field and change the “Start when” value to “Before”. The actual workflow actions only need to do one thing, which is to copy the value of the standard “Account Name” field to the new “Old Name” field. Nothing else.

    CRM_workflow_audit_2

    Next we’ll create a second workflow, called “Account Name Change: Post Old & New Name”. We’ll set it to run in real time for the account entity, just like the first one. We’ll even associate it with the very same event, meaning the change of the “Account Name” field. The difference will be that we’ll run this workflow “After” the event. Again, the actions that the workflow will perform are very simple, as we’ll only need it to create a new Activity Feed post record. Here’s how the message will be configured with the dynamic field values from the account record:

    CRM_workflow_audit_3

    So, we now have two real-time workflows running for the same entity, for the same field change event. Is this a smart thing to do? Will the universe by any chance collapse onto itself as a result of this reckless twin workflow configuration that we’ve built? Well, there’s only one way to find out! Let’s activate these two workflow processes, go to an account record and change it’s name.

    CRM_workflow_audit_4

    After the name is changed, we can click onto the Activity Feed’s auto posts column to refresh the post view. There we discover a post created by our second workflow process, containing both the “before” and “after” names for this account. Success! If we keep feeding further update events to this workflow duo, we can see that the post message is always updated to contain the last two names for this account in search of its true identity.

    CRM_workflow_audit_5

    If our second workflow process would have been an asynchronous process instead of real-time, the results might be different, though. As I’ve experimented in a previous post, “Auto-Numbering with CRM Workflows: Real-Time vs. Asynchronous”, the record data and execution order for traditional background workflow processes may not always be consistent, due to their asynchronous nature. By using a real-time workflow we are guaranteed to receive a ticket to the front row seats of CRM’s event execution pipeline. In practice this means the following:

    • “Account Name Change: Store Old Name” – this workflow is executed at the pre-operation stage, which means that it sees the record as it was before the update event took place. Therefore when it reads the account name field it still has the old value stored. Furthermore, because the workflow is completed before the actual platform event for the account update takes place, it can inject a new value into the “Old Name” field and have it committed to the database as a part of the original transaction.
    • “Account Name Change: Post Old & New Name” – this workflow is executed at the post-operation stage, meaning after the update has already taken place, but before the transaction is completely over. It receives an image of the account record where the standard “Account Name” field is populated with the new value the user has entered and the “Old Name” contains the value updated by the first workflow in the pre-operation stage.

    As this example scenario demonstrates, while a workflow can’t directly compare the “before” and “after” values of a record, there is actually a workaround available where you could pass the old value from the pre-operation workflow to the post-operation workflow. You could then perform a comparison of the values with the tools that the workflow editor offers (or extend it via custom workflow activities) and alter the outcome of the transaction based on the business logic. If needed, you could even cancel the operation and show an error message to the user if the old & new values are violating the rules of your business processes.

    To close things off, it’s important to keep in mind that just because you can do something with a workflow instead of custom code, it doesn’t mean it would always be the right tool for the job. Aside from the greater level of flexibility that a plugin will give you for comparing and manipulating the data during the update event, there are also performance considerations you should be aware of before pushing a ton of real-time workflows into your production CRM system. I recommend reading this post by CRM MVP Scott Durow: Real Time Workflow or Plugin?

  • Troubleshooting CRM for Tablets Login Issues with ADFS

    All CRM 2013 and CRM Online customers have access to the CRM for Tablets app that’s available for Windows 8, iOS and Android devices. Since it’s an app from the new age of mobile computing, the users can simply download it from the respective app store of the platform provider and install it. Configuring the app to connect with your CRM organization can however prove to be a bit trickier task than this.

    If you’re using CRM Online hosted by Microsoft in their data centers, connecting the tablet app to the CRM server in the cloud is usually a straightforward process. Just enter the URL for your organization, then punch in the credentials and off you go. Well, to be more precise, upon your first connection the organization you’ll be taken to a screen that asks you to hold on tight while the app is being set up. This is because all of the metadata related to your CRM organization’s customizations first needs to be loaded, so that you’ll see your own CRM instead of some generic, hard coded menus and fields. This step can take quite a while to finish, but just hold on tight, it’s worth it.

    If you’ve got your own on-premises CRM server or you’re logging to CRM Online via your on-premises Active Directory credentials, you may need to work a bit harder to achieve connectivity between the CRM for Tablets app and the CRM server. This is because in both of these scenarios you will have ADFS (Active Directory Federation Services) sitting there in the middle, processing your login request and validating your user credentials. Of course the same technology is also used behind the pure cloud CRM Online service, but MS has done the configuration work for you, whereas with on-premises components you’ll be in charge of performing this.

    CRM_for_Tablets_Were_Sorry

    Recently I was faced with a situation where a customer had deployed Dynamics CRM 2013 SP1 on-premises and done the Internet Facing Deployment via Windows Server 2008 R2 ADFS 2.0, published via Forefront TMG (Threat Management Gateway) 2010. Accessing CRM via the web client through the IFD address was working as expected, so was the CRM Outlook client. CRM for Phones was connecting without issues and I could even connect to the server via tools like XrmToolBox with no issues. There was just one problem: the CRM for Tablets wouldn’t connect to the server, no matter what. In the process of troubleshooting this particular scenario I learned a thing or two about the tablet app connectivity as well as server configuration tasks, so I thought I’d share my findings here on my blog. I’m by no means an expert on anything surrounding ADFS , but I’m stubborn enough to keep searching for answers until I find some from the great wide web.

    RTFM – Read The Friendly Manual(s)

    First of all, you’ll need to know your ADFS version, since there’s a few new hoops you’ll need to jump through when working with Windows Server 2012 R2 and the latest ADFS 2.2 (sometimes referred to as ADFS 3.0, since official version numbers seem to have been dropped by MS, in favor of just shipping ADFS together with Windows Server releases). The architecture of ADFS has changed considerably from earlier 2.0 and 2.1 versions, with no more IIS in the background, so the configuration process for CRM IFD also differs from the previous experience.

    You’ll find the extra steps listed on this article: Configure Windows Server 2012 R2 for CRM mobile clients. On the ADFS 2.2 server you’ll need to enable forms authentication manually, since it’s not enabled by default, like in previous versions. Then you need to run a Powershell script on the CRM server to configure the OAuth provider. Finally, you should register the CRM for Tablets app ID’s with the ADFS server via another Powershell script.

    Tablet_AD_login_promptYou may run into an issue with the login process where the user is prompted for their AD credentials via the standard Windows domain dialog window repeatedly. This is because of some incorrect authentication settings that apparently are caused by the CRM IFD configuration process itself. To avoid these issues, you should run a repair installation on the CRM 2013 server with the Web Application Server role deployed, after you’ve done the IFD configuration and before you attempt to log in with the CRM for Tablets app.

    Another aspect is the requirements imposed by the new Windows 8.1 version of the tablet app. Because of the changes on the OS layer, it’s no longer possible for Win8 apps to connect to any random server at will, but rather the developer has to specify the URL’s of these servers before publishing the app to the Windows Store. For CRM Online the domains for the service are known in advance, but for an on-premises deployment they could be absolutely anything. To overcome this, you’ll need to add a registry entry onto your device before attempting to connect to your server, otherwise the tablet app will just sit there and do nothing. Go to the page Set up CRM for Tablets, expand the section “what the admin needs to do” and grab the Powershell script from there. Running it on your device will prompt you for the CRM organization URL and create the necessary registry key for you. (more…)