Showing posts with label MS CRM 4.0. Show all posts
Showing posts with label MS CRM 4.0. Show all posts

Tuesday, March 31, 2015

Microsoft Dynamics CRM Installations, Updates and Documentation

This article lists all the installations, updates and documentation for the currently released MS CRM products.

List included For MS CRM 4.0, MS CRM 2011, MS CRM 2013 and MS CRM 2015

Click Here..

Microsoft Dynamics CRM Installations, Updates and Documentation


Tuesday, October 19, 2010

CRM / XRM virtual Groups

you can find the useful information about Microsoft CRM 4, MS CRM 2010, XRM on those blogs..

http://www.crmug.com/

http://www.xrmvirtual.com/

List of CRM blogs..

https://community.dynamics.com/content/crmblogs.aspx?GroupID=22


Some Useful links about MS CRM..
CRM SDK 4.0

http://www.microsoft.com/downloads/details.aspx?FamilyID=82E632A7-FAF9-41E0-8EC1-A2662AAE9DFB&displaylang=en

Easy Customizations for MS CRM
http://www.xrmshowcase.com/solutions/view?solutionid=d9e0f58e-fa81-430e-86fa-e67aa00c2d1e

Audit Capabilities
1. http://www.xrmshowcase.com/solutions/view?solutionid=c0ef7bcb-0a66-4658-aa95-b6da8ea30011

2. http://www.consultcrm.co.uk/add-ons.html

Javascript Grid Editor for CRM
1. http://www.xrmshowcase.com/solutions/view?solutionid=a0d69487-a91a-4063-8671-93c45e31fe4b

2. http://crmentropy.blogspot.com/p/javascript-grid-editor.html


PowerSearch for MS CRM 4.0 by mscrm-addons
1. http://www.xrmshowcase.com/solutions/view?solutionid=acd78d8b-f98f-4425-bc9d-10945abb7fa1
2. http://www.mscrm-addons.com/Products/AddonsforMSCRM40/ActivityToolsforMSCRM40/tabid/160/Default.aspx

Caching tool for Microsoft CRM

1. http://blogs.msdn.com/b/joris_kalz/archive/2006/08/09/caching-tool.aspx

2. http://blogs.msdn.com/b/joris_kalz/archive/2006/08/09/caching_tool.aspx

Limitations of XRM

http://www.xrmlinq.com/crm-sdk-4-0-12-bugs-limitations/


Link to run report from workflow

http://a33ik.blogspot.com/2009/08/custom-workflow-action-which-renders.html

Trigger N:N Association event and Dassiciation event in CRM Plugin

-- ===================================================================================================
-- Enable Associate and Disassociate Plug-in Events
-- execute the following query to CRM database, it will add two entries in SdkMessageFilterBase
-- 'DisassociateEntities' and 'AssociateEntities' from SdkMessageBase which is not listed
-- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
USE CrmDev_MSCRM
GO

-- Find the deployments SDK Filter ID for the
-- Associate and Disassociate Entity SDK Messages
DECLARE @DisassociateEntitiesFilterId uniqueidentifier
DECLARE @AssociateEntitiesFilterId uniqueidentifier
SET @DisassociateEntitiesFilterId = (SELECT SdkMessageId FROM SdkMessageBase WHERE [Name] = 'DisassociateEntities')
SET @AssociateEntitiesFilterId = (SELECT SdkMessageId FROM SdkMessageBase WHERE [Name] = 'AssociateEntities')

-- Enable the Associate and Disassociate Filters to be valid for custom processing
-- Custom Processing means "you register plug-ins against it"
-- Note: We only do this for the "generic" (OTC == 0) case, just to be safer
UPDATE SdkMessageFilterBase SET IsCustomProcessingStepAllowed = 1 WHERE SdkMessageId = @DisassociateEntitiesFilterId AND PrimaryObjectTypeCode = 0
UPDATE SdkMessageFilterBase SET IsCustomProcessingStepAllowed = 1 WHERE SdkMessageId = @AssociateEntitiesFilterId AND PrimaryObjectTypeCode = 0
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
The above query will enable the 'DisassociateEntities' and 'AssociateEntities' message in the plug-in registration tool. While registering the plug-in select the entity name as ‘none’

While executing the plug-in you will be getting four parameter as input parameters from the plug in context along with the other properties :

1. Related Entity1 GUID and entity name
2. Related Entity2 GUID and entity name
3. Relation hsip name (nothing but intersect hidden N:N entity name)
4. Optional parameter.

Using these value you can implement you logic.

Sample Code for N:N relationship with a custom entity and System User:

public void Execute(IPluginExecutionContext context)
{
try
{
crmservice = context.CreateCrmService(true);

if (context.MessageName == "AssociateEntities")
{

if (context.InputParameters.Properties["RelationshipName"].ToString() == "new_new_customentity_systemuser")
{
string oId = string.Empty;
string SharedUserId = string.Empty;

oId = (context.InputParameters.Properties["Moniker1"] as Moniker).Id.ToString();

SharedUserId = (context.InputParameters.Properties["Moniker2"] as Moniker).Id.ToString();

// write you logic here

}
}

}
catch (System.Web.Services.Protocols.SoapException ex)
{
LogWriter.LogInfo(ex.ToString());
}

catch (Exception ex)
{
LogWriter.LogInfo(ex.ToString());
}
}

Note : As we have defined 'none' as the entity name while registering the plug-in, so this plug-in will get triggered when ever user will do add existing or remove existing, for any entity. So while writing the logic relationship name is required to identify from where plug-in has been triggered.

References: http://consulting.ascentium.com/blog/crm/Post533.aspx
http://mscrm-chandan.blogspot.com/2010/03/trigger-nn-association-event-and.html

Wednesday, September 2, 2009

Some usefull links about CRM Custmization

CRM Form Types

Is the user creating a new record?
crmForm.FormType == 1

Is the user updating an existing record
crmForm.FormType ==2

Is the user unable to update this record?
crmForm.FormType == 3

Is this record deactivated?
crmForm.FormType == 4

Is the user using the Quick Create form?
crmForm.FormType == 5

Is the user using the Bulk Edit form?
crmForm.FormType == 6

What is the unique ID for this record?
= crmForm.ObjectId

What type of record is this?
= crmForm.ObjectTypeCode

What type of record is this (Entity Name)?
= crmForm.ObjectTypeName

Is the user using the Outlook Client?
crmForm.IsForOutlookClient==true

Is the user using the Outlook Light Client?
crmForm.IsForOutlookLightClient == true

Is the user working On line?
crmForm.IsOnline==true

Have any fields in this form been changed?
crmForm.IsDirty==true

Reference:
http://mscrm-developer.blogspot.com/2008/09/crm-form-types.html

=======================================
Use full JavaScripts

http://ronaldlemmen.blogspot.com/

=========================================
Hide menu bar in Iframe

http://crm.atechnisch.nl/2008/03/hiding-bars-in-iframes/

=============================================
Tricks and Tips from Users of Microsoft Dynamics CRM
http://crm.atechnisch.nl/2008/03/hiding-bars-in-iframes/

Tuesday, July 28, 2009

Find login user of CRM using JavaScript

var xml = "" +
"" +
"< soap:envelope chema-instance="" chema="" envelope="" http:="" schemas.xmlsoap.org="" soap="" www.w3.org="" xmlns:soap="\ " xmlns:xsd="\ " xmlns:xsi="\ " >" +

GenerateAuthenticationHeader() +

" < soap:body >" +

" < retrievemultiple crm="" ebservices="" http:="" schemas.microsoft.com="" xmlns="\" >" +

" < query crm="" http:="" q1:queryexpression="" schemas.microsoft.com="" uery="" xmlns:q1="\" xsi:type="\" >" +

" < q1:entityname>systemuser< / q1:entityname >" +

" < q1:columnset q1:columnset="" xsi:type="\" >" +

" < q1:attributes >" +

" < q1:attribute>businessunitid < / q1:attribute >" +

" < q1:attribute>firstname< / q1:attribute >" +

" < q1:attribute>fullname" +

" < q1:attribute>lastname" +

" < q1:attribute>organizationid " +

" < q1:attribute>systemuserid" +

" < /q1:attributes >" +

" < /q1:columnset >" +

" < q1:distinct>false" +

" < q1:criteria >" +

" < q1:filteroperator>And" +

" < q1:conditions >" +

" < q1:condition >" +

" < q1:attributename>systemuserid" +

" < q1:operator>EqualUserId" +

" < / q1:condition >" +

" < / q1:conditions >" +

" < / q1:criteria >" +

" < / query >" +

" < / retrievemultiple >" +

" < / soap:body >" +

"< / soap:envelope >" +

"";



var xmlHttpRequest = new ActiveXObject("Msxml2.XMLHTTP");



xmlHttpRequest.Open("POST", "/mscrmservices/2007/CrmService.asmx", false);

xmlHttpRequest.setRequestHeader("SOAPAction", "http://schemas.microsoft.com/crm/2007/WebServices/RetrieveMultiple");

xmlHttpRequest.setRequestHeader("Content-Type", "text/xml; charset=utf-8");

xmlHttpRequest.setRequestHeader("Content-Length", xml.length);

xmlHttpRequest.send(xml);



var resultXml = xmlHttpRequest.responseXML;

var entityNode = resultXml.selectSingleNode("//RetrieveMultipleResult/BusinessEntities/BusinessEntity");



var firstNameNode = entityNode.selectSingleNode("q1:firstname").nodeTypedValue;

var lastNameNode = entityNode.selectSingleNode("q1:lastname").nodeTypedValue;

var fullNameNode = entityNode.selectSingleNode("q1:fullname").nodeTypedValue;

var systemUserIdNode = entityNode.selectSingleNode("q1:systemuserid").nodeTypedValue;

var businessUnitIdNode = entityNode.selectSingleNode("q1:businessunitid").nodeTypedValue;

var organizationIdNode = entityNode.selectSingleNode("q1:organizationid").nodeTypedValue;


alert(systemUserIdNode );

Friday, July 17, 2009

Auto Generated Account Number using JavaScript

Here given JavaScript to access CRM data using web service, means we can call CRM webservice using JavaScript.

Main logic for generating Account Number

a. Find the last Account number assigned to account using web service.
b. Increment last account number by one.
c. Set new generated account number to account.

=============================================


To find last account number, we are using JavaScript, and we can write this Script on "OnLoad" or "onSave" event of account.

JavaScript


var authenticationHeader = GenerateAuthenticationHeader();
// Prepare the SOAP message.
var xml = ""+
"" xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'"+
" xmlns:xsd='http://www.w3.org/2001/XMLSchema'>"+
authenticationHeader+
""+
""+
"" xsi:type='q1:QueryExpression'>"+
"account"+
""+
""+
"new_AccountNumber"+
"
"+
"
"+
"false"+
"" +
" " +
" new_AccountNumber" +
" Descending" +
"
" +
"
" +
"
"+
"
"+
"
"+
"
";

// Prepare the xmlHttpObject and send the request.
var xHReq = new ActiveXObject("Msxml2.XMLHTTP");

xHReq.Open("POST", "/mscrmservices/2007/CrmService.asmx", false);

xHReq.setRequestHeader("SOAPAction","http://schemas.microsoft.com/crm/2007/WebServices/RetrieveMultiple");

xHReq.setRequestHeader("Content-Type", "text/xml; charset=utf-8");

xHReq.setRequestHeader("Content-Length", xml.length);

xHReq.send(xml);
// Capture the result.

var resultXml = xHReq.responseXML;
var results = resultXml.getElementsByTagName('BusinessEntity');
var i=0;
var lastAccountNumber= 0;
lastAccountNumber= results[i].selectSingleNode('./q1:new_AccountNumber).nodeTypedValue;

lastAccountNumber=eval(lastAccountNumber)+1
crmForm.all.new_AccountNumber.DataValue = lastAccountNumber;

}


Similary we can find any data of CRM entities using JavaScript and web service.

Hide any tab of CRM form

To hide any tab of MS CRM form, we are reuqired to write JavaScript on "OnLoad" event of that form.

Just add following line in OnLoad event

crmForm.all.tabTab.style.display = "none";

Replace with the index number of the tab.
The first tab has index 0, the second 1 and so on.

If the notes tab is the fourth tab in a form, the code will be

crmForm.all.tab3Tab.style.display = "none";