Customization and programming tricks by Ronny Van der Snickt

Extra options in optionset after import

After importing the product entity into a new organization I noticed something weird.

In my development environment I deleted all the options of the product type options set and created 2 new ones.

I exported this entity (unmanaged) and imported this in another clean organization.

The end result was that the product type had 6 options. The 4 default options and my 2 new once.

Which is kind of strange because I thought options get replaced when you import a solution. In this case the options merged.

I tried to reimport the same solution in the same organization again. Now I had only 2 options sets left.

So importing the same solution 2 times gives you different options sets. So again something extra to check when importing/exporting organizations…

Error on quote product: Precision must be an integer…

Had the following error when selecting a product on a quote detail form.

Precision must be an integer within the allowed range: 0 for integers, 0 to 4 for money, 0 to 10 for decimal, and 0 to 5 for float fields.

I first checked this.
http://social.microsoft.com/Forums/en-US/crmdevelopment/thread/8e02cea2-bef8-45d8-b67a-6cb360ad8f2c

But the selected item was already configured in the selected pricelist.
Read more »

DataValue Undefined in internet explorer 10

Using MS CRM 2011(rollup 12) I found out that crmForm.all.name.DataValue does not work anymore in IE 10. After setting compatibility mode for the site the DataValue property worked again. Keep this in mind if you haven’t upgraded your javascript code to use the new api and you want to use IE 10.

 

EDIT:
Oguz Kaan Akyalçın pointed out the HTC option, apparently turning it off and on again and then close IE 10 does the trick as well.

CRM Fix for HTC

My new default view for accounts.

Initially I had the view ‘Active accounts’ set as default. However I always used the same few accounts.
As I was no owner of these accounts, I couldn’t use the view ‘My Active Accounts’.
Solution: I changed my default view to ‘Accounts I Follow’ and selected the accounts I work with. Now I have a short overview of all the accounts I need.

 

Of course this will affect the posts in the What’s new section but in my case I already followed most of these accounts.

MS CRM 4.0 workflow assembly in a MS CRM 2011 solution

Just got this error when uploading a crm 4.0 workflow assembly in a CRM 2011.
Could not load file or assembly ‘Microsoft.Crm.Sdk, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35′ or one of its dependencies. The located assembly’s manifest definition does not match the assembly reference. (Exception from HRESULT: 0×80131040)
Found the solution at Rick Wilson blog link
Just add this after the configSections section in the web.config of the CRM 2011 website.
<runtime>
<assemblyBinding xmlns=”urn:schemas-microsoft-com:asm.v1″>
<dependentAssembly>
<assemblyIdentity name=”Microsoft.Crm.Sdk” culture=”neutral” publicKeyToken=”31bf3856ad364e35″ />
<bindingRedirect oldVersion=”4.0.0.0″ newVersion=”5.0.0.0″ />
</dependentAssembly>
</assemblyBinding>
</runtime>

Ghost project in TFS: Project site folder already exists

When I was working with Team Foundation Server and tried to delete and recreate a TFS project I got the following error.

Error
TF30004: The New Team Project Wizard encountered an unexpected error while initializing the Microsoft.ProjectCreationWizard.Portal plug-in.
 Explanation
TF30171: The Microsoft.ProjectCreationWizard.Portal plug-in used to create the new team project could not be initialized and returned the following error: TF30270: Project site folder “ProjectName” already exists.User Action
Contact your Team Foundation Server administrator.

 

—begin Exception entry—
Time: 2010-06-17 10:40:17Z
Module: Initializer
Event Description: TF30207: Initialization for plugin “Microsoft.ProjectCreationWizard.Portal” failed
Exception Type: Microsoft.TeamFoundation.Client.PcwException
Exception Message: TF30270: Project site folder “ProjectName” already exists
Stack Trace:
at Microsoft.VisualStudio.TeamFoundation.WssSiteCreator.Initialize(ProjectCreationContext context)
at Microsoft.VisualStudio.TeamFoundation.EngineStarter.InitializePlugins(MsfTemplate template, PcwPluginCollection pluginCollection)
— end Exception entry —

MS CRM 4.0 Setup error: ASP.NET is not installed

Today I got an error when installing MS CRM 4.0. Internet Information Services (IIS) => ASP.NET is not installed. (The screenshot is in Dutch but I tried the English installation too with the same results).

Screenshot setup ms crm 4.0

The log file didn’t helped much either Read more »

Show the number of records and space for each database table.

I created a nice SQL query today to show the number of records in each table in a database and the space it takes in the database in megabytes.

Very handy to see why some MS CRM databases are so big.

My biggest SQL transaction ever.

I just performed my biggest SQL transaction ever.

I had to delete 100 million DuplicateRecordBase records in de CRM database (More info)

 select count(*) from DuplicateRecordBase

 

I used the following SQL because using the delete statement filled up the hard disk and would have taken ages.

truncate table DuplicateRecordBase

Show subordinate records after merging accounts

First create an IFrame on your form, this will contain the associated view. In my case I’m using the account entity.
Read more »