CRM news and views from Simon Jackson

Sunday, February 07, 2010

CRM 4 Multi Entity Type Lookup

Create a single lookup on a CRM form that allows the user to select from multiple entity types. Download these two entities to see this in action.



The code is a class that you can implement, so it really should be easy to use. To use the class do the following steps:

On the entity that requires the multi entity type lookup:


  1. Add a N:1 relationship for each entity type that you want in the lookup.

  2. Add the look ups to the form, add one where you want the Multi Entity Type and the others to tab that we will hide from the user.


  3. In the onload paste in the class at the top:

  4. Call the class to setup the lookup



  5. Call the onsave method


  6. Please let me know if you find this useful by posting a comment.

Labels: ,

Adding a browse button (html input file control) to a CRM form

Here's a quick example of how to put a browse button (html input file control) on a CRM form and then populate another field when it changed. Put this into your onload and update the field name 'new_filepath' in the inputF_onChange method to the name of the field that you would to be populated with the full path.

inputF = document.createElement('input');
inputF.type = 'file';
inputF.onchange = inputF_onChange;

tbl = crmForm.all.tab0.getElementsByTagName('table');
if (tbl && tbl[0]) tbl[0].parentNode.insertBefore(inputF, tbl[0]);


function  inputF_onChange() {
if (inputF && inputF.value)
crmForm.all.new_filepath.DataValue = inputF.value;
}

Here's a list the members exposed by the input type=file object.
http://msdn.microsoft.com/en-us/library/ms535263(VS.85).aspx

It should be noted that the above example will not work for IE8 as JavaScript can no longer read the full path from the value property.

As an alternative I would recommend trying a more supported method, for example, create an ISV page with the input file control and read the path server side and use javascript to populate the control on the parent CRM form.

Labels: ,

Thursday, February 04, 2010

Microsoft CRM 4.0 Update Rollup 7 and "Internet Explorer has blocked this site from using an ActiveX control in an unsafe manner."

Rollup 7 adds a new “Configure CRM” button to setup the Outlook client. The button uses an ActiveX control to read your CRM Outlook client, which can causes IE to display "Internet Explorer has blocked this site from using an ActiveX control in an unsafe manner."

This occurs when you have the Microsoft Office Outlook installed but not configured, or if you are connecting to an organisation other than the organisation for which Microsoft Dynamics CRM for Microsoft Office Outlook is configured.


This issue is mentioned in http://support.microsoft.com/default.aspx/kb/976539


A solution is mentioned here http://support.microsoft.com/kb/2004601


You can either change the IE security zone on the client or update the registry on the server. To update the sever registry, follow these steps:

  1. Open Regedit
  2. Navigate to:HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM
  3. A a new 32bit DWORD called DisableOutlookSetupLink
  4. Set the value to 1 to disable the CRM for Outlook button for all users.

Labels: ,

Wednesday, February 03, 2010

about:blank not always trusted, so not such a good default url for your CRM IFrame

Basically when setting a default page for your Crm Forms IFRAME about:blank can have a trust issues in the browser and it's better practice to use /_static/blank.htm instead.

This nice article from those ascentium guys explains why.
http://xrm.ascentium.com/blog/crm/Post612.aspx

Labels:

Monday, November 03, 2008

Optimising VPC Speed

I've started to use the following batch file to stop some unnecessary services in my CRM development virtual machine to help optimise it's speed.

As you can see below this is not specific to CRM so will come in handy for my other environments.

@echo off
@echo -- Stopping unnecessary services for optimal VPC speed
@echo
@echo -- ... Stopping "Help and Support" service
net stop "Help and Support"
@echo -- ... Stopping "Print Spooler" service
net stop "Print Spooler"
@echo -- ... Stopping "Error Reporting Service" service
net stop "Error Reporting Service"
@echo -- ... Stopping "Task Scheduler" service
net stop "Task Scheduler"

Labels: ,

Wednesday, October 22, 2008

Crm Tracing on Server 2008 problem

I was pulling my hair out trying to get Crm4 tracing working on Server 2008 deployment, I logged onto the server made changes to the tracing registry settings but CRM did create any tracing files. So I double checked them all seemed ok!

At first I thought it was permissions to the trace directory but it transpires this was caused by User Account Control(UAC) virtualising the registry.

http://msdn.microsoft.com/en-us/library/aa965884.aspx

While the registry looked fine to my user account it was a virtual copy! CRM was reading the registry but it didn’t have any trace settings.

Turning off the registry virtualises for the CRM keys, this meant I could change the trace settings. I ran the following from an administrator console to turn off visualisation

REG FLAGS HKLM\Software\Microsoft\MSCRM SET DONT_VIRTUALIZE /s

Alternately I think I could have made the changes to the registry under the context of the CRM Application Process so that CRM would see the changes.

Labels: , ,

CreateCrmService incorrect url, CrmService fails with 404 - Not Found

I deployed a plug-in today to one of our clients dev server only to get a strange “404 - Not Found” exception being reported. The exception was raised from the CrmService, the service object was returned from context.CreateCrmService so it should of been ok. Digging deeper I could see that the URL was pointing to localhost which is incorrect as it should have been the host header http://crm.mydomain.fqdn, as always Google had the answer.

I found a great post where George Doubinski has reflected the issue and highlights the CRM bug

There’s a hot-fix for the issue kb950542 at the time of writing this had to be requested from MS.

Labels: , ,

Sunday, August 31, 2008

CRM4 JScript Export Tool

Joris Kalz has released a small tool to extract the JScript from CRM forms and put them into individual files. His post can be found here.

IMHO I think I'll find this useful for source control and handy when used in conjunction with David Yack's JScript Intellisence solution.

Labels: ,

CRM4 Outlook Client Fixes from KB950088

Microsoft has released a hotfix package for KB950088is a cumulative hotfix which resolve all the issues below:

1. Outlook hangs during initialization (progress toolbar displays “Loading…” and never finishes)

This must-have fix is likely the most common perf/stability issue out there, especially on Outlook 2007. This fix resolves the issue. A current workaround exists by turning off the To Do bar.
http://support.microsoft.com/kb/952724

2. With E-mail Auto Promotion Enabled, Outlook may not close cleanly/properly.

This fix addresses a memory allocation issue that can occur somewhat unpredictably. If your users are using e-mail auto promotion, I encourage you to deploy this hotfix.

http://support.microsoft.com/kb/948121

3. Contacts with birthdays earlier than 1/1/1970 causes Outlook to crash

This was caused by an API change by one of our dependencies.

http://support.microsoft.com/kb/948045

4. Items in Shared Calendars will report Sync Issues

We do not support Shared Calendars in CRM 4.0, we encountered a couple of cases where some code was getting executed against a shared calendar and causing problems.

http://support.microsoft.com/kb/949086

5. Cannot Promote an E-mail where the name of the attached file contains a ‘&’ symbol.

If the attachment to an e-mail contains the ‘&’ symbol, it will fail to track in CRM.

http://support.microsoft.com/kb/949719

6. Selecting Dismiss on Outlook Calendar reminder for Service Activity causes record to change Status Reason back to default value for that record.

Selecting Dismiss on Outlook Calendar reminder for Service Activity causes record to change Status Reason back to default value for that record

http://support.microsoft.com/kb/950475

7. OWA Sent Emails Get Stuck in Outlook Draft Folder When Outlook Is Open And CRMADDIN is Enabled

When you have both Outlook and OWA open, and you have the Microsoft Dynamics CRM client for Microsoft Office Outlook installed, and you send an email form OWA, the email will be stopped in the Draft folder instead of being sent

http://support.microsoft.com/kb/950088

Labels: , , ,

Enable Jscript Intellisense for CRM by Leveraging Visual Studio 2008

The promise to have Jscript intellisence over the crm JScript object model has me sold
on the book "CRM as a Rapid Development Platform" (electronic version $49.99) by David Yack.

On David's site you can find a videocast demonstrating the benefit's of intellisence for Crm JScript and how to achieve it. Enable CRM JScript Intellisense

As far as I am aware you need to buy the book to obtain the code that helps you achieve the intellisence in VS 2008.

Labels: , ,

SharePoint List Web Part for Microsoft Dynamics CRM 4.0

I've been reading the Microsoft Dynamics CRM "Statement of Direction" that's was updated in August 2008. And noticed the following regarding SharePoint List Web Part for Microsoft Dynamics CRM 4.0:

"The current List Web Part for Microsoft Dynamics CRM 3.0 provides a subset of the Microsoft Dynamics CRM 3.0 record list functionality. It allows users to view Microsoft Dynamics CRM 3.0 records as a list from a SharePoint page, open records in Microsoft Dynamics CRM 3.0 from that list, and connect different Microsoft Dynamics CRM 3.0 List Web Parts to filter associated CRM lists. It supports the following versions of SharePoint:
- Microsoft Windows SharePoint Services 2.0
- Microsoft Office SharePoint Portal Server 2003
- Microsoft Office SharePoint Server (MOSS) 2007 (32-bit only)
- Microsoft Windows SharePoint Services (WSS) 3.0 (32-bit only)
The CRM records are displayed in a grid that behaves similarly to the grid within Microsoft Dynamics CRM 3.0. Users who have the proper privileges can perform actions such as create and edit.

Due out in the second half of 2008, there will be an updated SharePoint List Web Part for Microsoft Dynamics CRM 4.0. This web part will have the same features as the previous release but will also support the following:
- The multi-tenancy architecture of Microsoft Dynamics CRM 4.0; the web part is
configured with the Microsoft Dynamics CRM organization that will supply the list data.
- Support for CRM on-premise and Internet Facing Deployments (IFD); support for Microsoft
Dynamics CRM Online will be added in the first half of 2009.
- MUI and language packs in all languages supported by Microsoft Dynamics CRM 4.0
- MOSS and WSS 64-bit environments
"

I've been waiting for this upgrade for ages and will be very happy to see it released (in the near future).

Labels: ,

Tuesday, October 30, 2007

CRM 4

I’ve been following the release of Microsoft CRM 4 with great interest. Having deployed CRM 3 to many clients I’m all too aware of the limitation you hit customising CRM 3.

Philip Richardson is the CRM Lead Program Manager, he has released many of the screen casts below on his blog. These should let you see some of some of the new features in action.

Some of the new features are:
  • Multi-currency: Oh not just localized versions, but the ability to mix currency choice within one specific company.
  • Multi-language: The same as above and a big thank you to the team from the many companies with multiple global offices!
  • Support for roaming profiles when using terminal service environments
  • Significant development around increased WAN performance
  • Multi-layers of advanced duplicate detection. A major thank you from me to the team! They went above and beyond on this one (although this demanding little gemstone can always find more to want)
  • Support for SQL Monitoring and SQL Clusters
  • Support for alternative deployments
  • "self updating" installation
  • Diagnosis and process monitoring
  • Embedded Auto-Complete on numerous fields
  • More Bulk Changes and Data Cleansing features
  • Web Based Mail Merge
  • A new Report Wizard to empower customers to extract all the data they want to extract in the way they want to extract it
  • Integration with Office Communicator (think embedded IM)
  • Presence control (who is on-line)
  • 360 Degree View of the Customer
  • Cross entity advanced find enhancements
  • Role based report foundation
  • New Deployment Wizards which include bulk importing of users from Active Directory
  • OneNote Integration
  • A new level of Bi-Directional integration to Excel (Export to Excel, make changes, re-import into DynamicsCRM)
  • New workflow Wizards, Templates and libraries
  • Web based/Client Workflow configuration
  • Break down any workflow into stages
  • Multi-criteria e-mail tracking. E-mail tracking token can be turned off.
  • New more flexible licensing options such as device versus user CALs
  • Role based Report Foundation - Reporting can be dependent on the user's rights, security and roles
  • New Microsoft Dynamics CRM Resource Center
  • Reconfiguration/Redesign of the Outlook Client for CRM to allow for the wide variety of outlook footprints and variables in the field
  • Diagnostic Tools in the Outlook for CRM client
  • The Windows Workflow Foundation (WWF) with more integration to MOSS (SharePoint)
  • Many to Many Relationships
  • System to System Relationships
  • Pop3 Support/Exchange 2007 Support (64 bit)
  • Direct External Interface into Dynamics CRM without a required VPN
  • Asynchronous processing
  • Offline and On-line use is consistent no change of features when offline
  • New Data Mapping features
  • Multiple ways to Authenticate
  • Various components from within Dynamics CRM can be split out onto different application servers including API Calls, WorkFlow, UI Calls, etc.
  • Greater Organization Visibility
  • New Client Migration Toolkit
  • Multi-Tenant platform for enterprise hosting
  • E-Mail Topology changed to support more multiple choices of e-mail routing
  • E-mail routing can be done without Exchange
  • Reporting stored within the database for easy disaster recovery planning

Labels: ,