Friday, July 29, 2011

The Get Started pane can be displayed or hidden by default in ms crm 2011

The Get Started pane can be displayed or hidden by default on a per user basis or CRM Administrators can set this configuration for all system users.
This will help to laod the main page bit 1st.
so do it click file -> options and just select or deselect the Show Getting Started panes on all lists check box accordingly as in the image.
hope it will help a lot

Working with Microsoft Dynamics CRM 2011

Optimizing and Maintaining the Performance of CRM Clients in MS CRM 201

General Approach to Optimization and MaintenancePerformance tuning and optimization is a continuous balancing act between design decisions and resource availability. Consider taking the following high-level approach when optimizing and maintaining the clients that access a connected system such as Microsoft Dynamics CRM.
Note: Because Microsoft Dynamics CRM clients are CPU and memory intensive, the level of the hardware on which a client is running directly affects the performance of that client, with better hardware configurations yielding better performance results.
Important: Regularly downloading and installing the latest hotfixes and update rollups is always a first step in efforts to enhance and maintain the performance of clients that are accessing a Microsoft Dynamics CRM implementation. For a listing of current resources, updates and hotfixes available for Microsoft Dynamics CRM Online or Microsoft Dynamics CRM 2011, see the Dynamics CRM Solution Center at: click here
Factors Affecting Microsoft Dynamics CRM Client PerformanceMicrosoft Dynamics CRM client performance can be directly affected by several factors:
 Level of hardware and versions of software present in the computer running the client
 Extraneous processes and applications running on the same computer
 Characteristics of the network over which client access occurs
 Level and complexity of customizations applied to the solution
In addition, Microsoft Dynamics CRM for Outlook performance can potentially be affected by:
 The number of Microsoft Dynamics CRM organizations that a single instance of Microsoft Dynamics CRM for Outlook is configured to access. By default, Microsoft Dynamics CRM for Outlook is configured to access and display information from a single “primary” Microsoft Dynamics CRM organization, but it can also be configured to display information from one or more secondary organizations. An increase in the number of organizations that a single instance of Microsoft Dynamics CRM for Outlook is configured to access has a corresponding increase in the requirement for client memory.
 The volume of data that is processed during:
o Outlook synchronization
o Offline synchronization (Microsoft Dynamics CRM for Outlook with Offline Access only)
Hardware and Software Requirements
The performance of a Microsoft Dynamics CRM client is directly affected by the hardware on which that client is running, with higher-level hardware configurations (especially the level of processor and amount of memory) typically yielding better performance. In addition, there are specific software requirements associated with running Microsoft Dynamics CRM clients. As a result, be sure to verify that computers running Microsoft Dynamics CRM clients meet the appropriate hardware and software requirements according to their usage.
Important: Later versions of Internet Explorer provide enhancements that improve page rendering. As a result, it is recommended that computers running Microsoft Dynamics CRM clients be installed with the latest version of Internet Explorer that is supported within a specific business environment.
Extraneous Processes and ApplicationsAll the processes and applications running on a client computer can adversely affect the performance of Microsoft Dynamics CRM clients. For client computers with hardware at or near minimal-level requirements, consider turning off non-critical business processes, video streaming, and software such as games and music programs, to accelerate performance. Because this issue can have a greater impact on client computers configured for offline access, third-party add-ins for Microsoft Office Outlook can also be disabled to improve the performance of Microsoft Dynamics CRM for Outlook.
Note: Some desktop security software packages, especially those that scan all webpages for malicious JScript, are known to cause performance issues with web-based applications such as Microsoft Dynamics CRM. Most of these programs provide the ability to disable scanning on specific web sites, and adding the URL of the Microsoft Dynamics CRM organization to a list of exclude sites can help to improve performance in these situations. For other types of anti-virus software, make sure the URL of the Microsoft Dynamics CRM organization is included in the trusted zone for the virus scanning and disable “on-access scanning” for the site. See your specific anti-virus application documentation for more details.
Important: Each environment requires a thoughtful decision on what to include and exclude, and there is always a possibility that excluding files from scans can lead to unwanted consequences. Be sure to consider this option together with the well planned internal IT management policies established for a specific scenario.
Extraneous Processes and Applications
All the processes and applications running on a client computer can adversely affect the performance of Microsoft Dynamics CRM clients. For client computers with hardware at or near minimal-level requirements, consider turning off non-critical business processes, video streaming, and software such as games and music programs, to accelerate performance. Because this issue can have a greater impact on client computers configured for offline access, third-party add-ins for Microsoft Office Outlook can also be disabled to improve the performance of Microsoft Dynamics CRM for Outlook.
Note: Some desktop security software packages, especially those that scan all webpages for malicious JScript, are known to cause performance issues with web-based applications such as Microsoft Dynamics CRM. Most of these programs provide the ability to disable scanning on specific web sites, and adding the URL of the Microsoft Dynamics CRM organization to a list of exclude sites can help to improve performance in these situations. For other types of anti-virus software, make sure the URL of the Microsoft Dynamics CRM organization is included in the trusted zone for the virus scanning and disable “on-access scanning” for the site. See your specific anti-virus application documentation for more details.
Important: Each environment requires a thoughtful decision on what to include and exclude, and there is always a possibility that excluding files from scans can lead to unwanted consequences. Be sure to consider this option together with the well planned internal IT management policies established for a specific scenario.
Network CharacteristicsThe primary characteristics of a network that affect the performance of Microsoft Dynamics CRM clients are bandwidth and latency.
 Bandwidth is the width or capacity of a specific communications channel.
 Latency is the time required for a signal to travel from one point on a network to another; latency is a fixed cost between two points.
Important: It is recommended to test the implications of client performance in any WAN environment with potential bandwidth or latency issues, which can vary greatly from performance in a LAN environment
Level and Complexity of CustomizationsWhen optimizing the performance of Microsoft Dynamics CRM clients, keep in mind that client performance is directly affected by the:
 Number of:
o Columns and grids in use
o Rows returned per page
o Sub-grids used on a page
o Controls on a form (Form Design)
o Controls on the ribbon
 Complexity and number of visualizations used in dashboards
 Use of Jscript and Plugins. Advanced Jscript can add a significant amount of time to, open, save, close and other events especially if calls are made to Microsoft Dynamics CRM or other system. Also plug-ins can affect performance when saving.
 Also if you have any JS on onload event of the page
Configuring Internet Explorer for Optimal PerformanceConfiguring Client-Side Browser CachingClient-side browser settings can greatly affect user experience over slower connections. Internet Explorer 7 and later versions are configured to managed client-side browser caching automatically by default.
However, at times it may be advisable to increase the hard disk space reserved for temporary Internet files to help optimize performance by ensuring that the cache has adequate room to take advantage of improved load times when making subsequent visits to the same page for the same files.
 To configure client-side caching
1. On the client computer, in Internet Explorer, on the Tools menu, click Internet Options.
2. In the Internet Options dialog box, on the General tab, under Browsing history, click Settings.
3. In the Temporary Internet Files and History Settings dialog box, under Check for newer versions of stored pages, verify that Automatically is selected.
4. In the Disk space to use box, specify a value from 50 to 250 megabytes of disk space for temporary Internet files, and then click OK.
Important: In the Internet Options dialog box, on the General tab, under Browsing history, also verify that the Delete browsing history on exit check box is cleared to prevent the deletion of temporary Internet files each time that the browser is closed.
5. On the Advanced tab, under Settings, scroll down and verify that the Do not save encrypted pages to disk check box is cleared, and then click OK.
Note: After the client-side browser settings on a computer are modified, loading the Dynamics CRM Web client for the first time (the “cold” load) may take several moments longer than usual. Subsequent page loads (“warm” loads) will show improved performance, however, as many of the Microsoft Dynamics CRM Web pages will have been cached during the initial load.

Configuring Simultaneous Download SessionsBy default, Windows Internet Explorer 7 and earlier versions limit the number of files that you can download at one time to two. Windows Internet Explorer 8 limits the number of files that you can download at one time to six. This change reflects the faster connection speeds that are now typical for most users. Note that for dial-up connections, the limits from earlier versions still apply.

Important The following procedures require modification of the registry, which can create serious problems if the registry is modified incorrectly. As a result, be sure to follow these steps carefully and for added protection, back up the registry before making any changes.
 To increase the number of files that can be downloaded at one time to 10
Internet Explorer 7.0
1. Start Registry Editor, and then navigate to the following key:
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings
2. On the Edit menu, point to New, click DWORD Value, and then add the following registry values:
Value name: MaxConnectionsPer1_0Server
Value data: 10
Base: Decimal
Value Name: MaxConnectionsPerServer
Value data: 10
Base: Decimal
3. Exit Registry Editor.
Internet Explorer 8.0
1. Start Registry Editor, and then navigate to the following key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_MAXCONNECTIONSPERSERVER
2. On the Edit menu, point to New, click DWORD Value, and then add the following registry value:
Value name: iexplore.exe
Value data: 10
Base: Decimal
Note set this value to the connection limit that you want for HTTP 1.1 connections. By setting the value to 10, you increase the connection limit to 10.
3. Navigate to and select the following subkey:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_MAXCONNECTIONSPER1_0SERVER
4. On the Edit menu, point to New, click DWORD Value, and then add the following registry values:
Value name: iexplore.exe
Value data: 10
Base: Decimal
Note set this value to the connection limit that you want for HTTP 1.1 connections. By setting the value to 10, you increase the connection limit to 10.
5. Exit Registry Editor. 

Configuring Microsoft Dynamics CRM for Outlook for Optimal PerformanceThere are several configuration techniques available for optimizing the performance of Microsoft Dynamics CRM for Outlook, which are detailed in the following sections.
Note: Over very high latency connections, often a Terminal Services/Citrix connection will improve performance. Note that Terminal Services/Citrix connections are only accessible via Microsoft Dynamics CRM for Outlook; Terminal Services does not support Microsoft Dynamics CRM for Outlook with Offline Access.
Optimizing the Outlook Synchronization Process
To optimize the performance of Microsoft Dynamics CRM for Outlook, configure the filters associated with the Outlook synchronization process to affect the fewest record types and to occur as infrequently as possible without compromising business requirements and to avoid creating duplicate records if key fields match.
 To set Outlook synchronization options for optimal performance
1. In Outlook 2003 or Outlook 2007, on the CRM menu, click Options.
- OR -
In Outlook 2010, on the File tab, click CRM, click Options.
2. In the Set Personal Options dialog box, on the Synchronization tab, under Synchronize Microsoft Dynamics CRM items with my default Outlook folders, click Outlook Filters.
3. In the Filter: Outlook dialog box, on the User Filters tab, click the name of the filter that you want to edit, or on the Actions toolbar, click New to create a new filter, and then edit the filter as necessary.
Note: You can also use the Filter: Outlook dialog box to specify the status of an existing Outlook filter as either Active or Inactive.
4. Click OK to save any changes and close the Filter: Outlook dialog box.
5. To define the frequency with which the Microsoft Dynamics CRM items in your Microsoft Dynamics CRM for Outlook folders are updated in the background, in the Set Personal Options dialog box, select the Synchronize the CRM items in my Outlook folders every check box, and then specify the number of minutes between each update.
Using this feature provides the user with the convenience of not having to remember to synchronize Microsoft Dynamics CRM with Outlook manually.
Important: An organization must permit a user to change the Synchronize the CRM items in my Outlook folders every check box, and the administrator sets the minimum time allowed between synchronizations.
6. Click OK to save any changes and close the Set Personal Options dialog box.
Optimizing Address Book PerformanceTo optimize Address Book performance, configure the Address Book to match only against the contacts that are synchronized to Microsoft Dynamics CRM and to retrieve updates as infrequently as possible without compromising business requirements.
 To set Address Book options for optimal performance
1. In Outlook 2003 or Outlook 2007, on the CRM menu, click Options.
- OR -
In Outlook 2010, on the File tab, click CRM, and then click Options.
2. In the Set Personal Options dialog box, on the Address Book tab, under Select how e-mail recipients are reconciled with Microsoft Dynamics CRM records:
• For Contacts, choose whether names and e-mail addresses from the address book are compared to some or all of your Microsoft Dynamics CRM contacts.
o Match only against contacts synchronized to Microsoft Dynamics CRM specifies to link e-mail messages to the Microsoft Dynamics CRM contact records that you have chosen to synchronize and also match a name or e-mail address in your address book. This option is selected by default.
o Match all contacts in Microsoft Dynamics CRM specifies to link e-mail messages to any Microsoft Dynamics CRM contact record that also matches a name or e-mail address in the address book.
• For Other record types, choose whether you want to link e-mail messages to other record types if the names and e-mail addresses in the other record types match those in the address book; also choose the types of records.
o Do not match specifies not to link e-mail messages to other record types
o Match only the items I own specifies to link e-mail messages to other records types. This option is selected by default.
o Match all items in Microsoft Dynamics CRM specifies to link e-mail messages to all record types in Microsoft Dynamics CRM
3. Under Select how often the Outlook Address Book should be updated from Microsoft Dynamics CRM, select the Update the Outlook Address Book every check box, and then in the box to the left of hours, type in the number of hours you want between each Address Book update.
Click OK to save the changes and close the Set Personal Options box dialog box.
Pinning Commonly Used ViewsWith Microsoft Dynamics CRM for Outlook, users can open tabs to display multiple views of an entity. Users can also “pin” views so they always display when a user logs in to Outlook. Pinned views, which are stored in cache, respond more quickly than do standard views, so be sure that suggest that users “pin” the views with which they most commonly interact.
Important: Each pinned view consumes system resources (memory), so balance the use of pinned views against the need for system resources.

 To pin a view in Microsoft Dynamics CRM for Outlook
1. In Outlook, click the tab to the right of the active tab, and then select the view to pin.
2. On the tab, click the push pin symbol (the symbol will turn vertically).
The view is now ‘pinned,’ so that the next time the user logs on, the pinned view will display rather than the default view.
Customizing Microsoft Dynamics CRM for Optimal Client Performance
When customizing Microsoft Dynamics CRM for optimal performance of the Microsoft Dynamics CRM clients, keep in mind the following best practices.
 Use JScript judiciously. While a few lines of JScript can greatly enhance the user experience by automatically updating data as a form loads or as data is changed, they can also cause a performance issue if a lot of JScript code is running on a form. When using JScript on forms, verify that code is optimized to ensure efficient form loads.
Note: To determine if JScript is affecting the performance of a form, remove the JScript and test how the form performs. Then, compare those results to the performance of the form with JScript included.
 Use iFrames judiciously. The greater the number of iFrames on a form, the greater the associated form load time will be. If an iFrame is not on the form’s primary tab, use collapsed tabs and set the URL in the TabStateChange Jscript event for the tab on which the iFrame resides. This ensures that the iFrame loads only when a user clicks the tab, rather than loading each time a record is opened.
 Use sub-grids judiciously. Each sub-grid that is used in a form queries the Microsoft Dynamics CRM system in the background for a set of data to load into the grid. While the query executes in the background, each sub-grid control on a form adds more HTML to the page, resulting in longer load times. For sub-grids that are in use, consider having users collapse them, as data will not be retrieved until the user expands a sub-grid.
Important: Each sub-grid also includes a context-sensitive ribbon to provide users with access to the appropriate commands for that sub-grid. Although the ribbon only becomes visible when the grid is selected, the required xml (and therefore the processing) occurs as the form is loaded. As a result, even if a user never selects the sub-grid, there is a performance impact associated with each sub-grid on a form.
 Use role-based forms to limit the fields that display on a form to accommodate the specific requirements of users based on their assigned security role.
 Adjust security roles to limit the functionality presented to users based upon their specific requirements for selected record types. This ensures that the user interfaces adapts to display only the elements required by specific users to work with data in the Microsoft Dynamics CRM solution.
 Customize forms to display only the fields required for specific types of records.
 Consider the complexity and number of visualizations used in the dashboards on a page. Dashboards capture a lot of data and are loaded separately in parallel connections to the rest of the page. As a result, limit the number of visualizations used in a dashboard as much as possible without compromising business goals.
 Use columns and grids judiciously. Optimize views and sub-grids so that only the required columns and grids display by default.
 Limit the number of rows that are returned per page while still meeting any related business requirements.
 After users are sufficiently familiar with Microsoft Dynamics CRM, hide the Get Started pane to reduce any impact it might have on client performance.
Note: The Get Started pane can be displayed or hidden by default on a per user basis or CRM Administrators can set this configuration for all system users.
 To set Get Started panes to display or hide for a specific user
1. In Outlook 2003 or Outlook 2007, on the CRM menu, click Options.
- OR -
In Outlook 2010, on the File tab, click CRM, and then click Options.
2. In the Set Personal Options dialog box, on the General tab, under Select the setting for Get Started Panes, select or deselect the Show Getting Started panes on all lists check box accordingly.
3. Click OK to save any changes and close the Set Personal Options dialog box.
 To set Get Started panes to display or hide for all users
1. In Outlook 2003, Outlook 2007, or Outlook 2010, on the Navigation Pane, click Settings, click System, click Administration, and then click System Settings.
2. In the System Settings dialog box, on the General tab, under Select the display option for Get Started Panes, select or deselect the Show Getting Started panes on all lists for all users check box accordingly.
3. Click OK to save any changes and close the System Settings dialog box.

Working with Microsoft Dynamics CRM 2011

Wednesday, July 27, 2011

enable tracing in ms crm 2011

in ms crm we can enable the tracing to find out the difficulty of any exception in details.
it can be done so easily, just need to configure.
just run a command regedit to open the registration key editor
then track upto the softwares/microsoft/mscrm
now add three keys here
TraceDirectory -- c:\CRMTrace as string
TraceEnabled -- 1 as dword //0 means disabled and 1 means enabled
TraceRefresh -- 1 as dword

not it may require a iisreset else u can do recycling of the crmapppool

u will find the trace file under /trace folder in the fiel of todays date.

do not forget to disable the trace after you are done, else thsi will slow down the application.

thanks

disable a button in ribon on basis of a attribute value in the form in MS CRM 2011

sometimes we have to hide some buttons in ms crm 2011.
that we can do and i hv posted in some of my post, bu using the HideCustomAction tag.

Here i will put how to disable a button on basis of a logic or value (also can be done by user role) on the form of ms crm 2011.

1st you need to export the entity.

Then find the id of the button, then get command value from the button tag.
now go to the comanddefinitions tag and find the comamnddefition with the corresponding id.
Inside that u will have to declare your enablerules tag as follows
<EnableRules>
<EnableRule Id="Mscrm.Isv.contact.Form.Group0.Control0.EnableRule" />
</EnableRules>
then go RuleDefinitions tag insdie the same xml file and define the rule for enable as below
<EnableRules>
<EnableRule Id="Mscrm.Isv.contact.Form.Group0.Control0.EnableRule">
<CustomRule FunctionName="disableEditButton" Library="$webresource:<js file name.js" /> //here u can define the js file u have kept the webresources and also the functionname which will be executed for this
</EnableRule>
</EnableRules>

In your js file you can have the fucntion as declared.
main thing is write your logic and return boolean value.
suppose i am just checking is an attribute has value then only i will make enabled else disabled.
function disableEditButton(){
if(Xrm.Page.data.entity.attributes.get("<attributename>").getValue() != null){
return false; // false means it will be disabled
}else{
return true; //means it will be true
}
}

hope this will help.
even you can use the valuerule tag to push direct values in the xml file.

Limit the No of records a user can see per page in a view in MS CRM 2011 or ms crm 4.0

Couple of time you might see a requirement like,or user demand like, ‘user should only see 10 records per page in a view in the entire MS CRM

You can set this in the Personal options by setting the Records Per Page:

Though records per page can set minimum 25 and maximum 250.

if some one wants to restrict to some specif number say10 records per page??

here is the solution..
even if its unsupported, still full filling the requirement.. so...
run the below SQL against the Organization you desired to do so.
1st u need to get the system user guid
select SystemUserId from SystemUserBase where DomainName='>DomainName\username<'
then use the system guid an dfire the below query
update UserSettings set PagingLimit=10 where SystemUserId='<<GUID of the USER>>'

hope this helps....

Monday, July 25, 2011

Auto Refresh of Grids on form , while loading, ms cmr 2011

In MS CRM 2011, we got a very good feature as of adding the inline grid on form with easily.
So, while loading sometimes it will not load the records automatically, but will give a hyperlink saying ckilc here to laod the records.
If you want to load it automatically(cuz some crazy users do't want another click to load), just get the name of that grid, by double clicking the grid in the design view of the form.
then onload of the form call the below function by passing the name of that grid.

function _loadGridAutomatically(_gridName){
if(document.getElementById(_gridName) != null){ //make sure the grid is there
_gridName.Refresh(); // this will do d magic
}
}

hope this will help to the developer for such crazy(lazy) users....

Thursday, July 21, 2011

Filtered Lookup onclick of a pickList(Optionset) MS CRM 2011

Hi, all we know that the beautiful feature in MS CRM 2011, has given the filtered lookup.
this u can do as in figure
•Selecting which view to use to display possible Lookup selections, as well as controlling which Views the CRM User is allowed to select from.
•Selecting a filter to show only records that match a certain dynamic criteria, with the option to control whether the User is allowed to remove the Filter or not.
This allows us to control how the Lookup will appear in CRM 2011 through simple customisation, and so avoid developing any code to produce a Filtered Lookup.

While creating the lookup, by configuring it, we can get the filtered values.
Here i am going to put, how can i get the filtered lookup values on basis of a value from the slected picklist(optionset).
IDs i have used here, so u need to have these things in your hand

Parent Entity : new_parententity
optionsetname : new_optionset
lookupattribute : new_childenitytid (this is in the parent enity, this will be present in the form, but can be hidden)

lookup entity : new_childentity
id: new_childentityid
objecttype : , this u can get, just open a recird and see the etc in the url
list the columns u want: new_column1,new_column2,createdon
condtional attribute : new_conditionaloptionset

now onchange of your picklist call the following function

function onchange_new_optionset(){
//get the optionset value and index
var name = 1;//get the value
var value = 'values of the selected optionset';
_setLookup(name, "ihis_polyclinicid", value);
document.getElementById("ihis_polyclinicid").click(); // this is tricky part, onchange of teh optioset, fire the click event of the lookup filed which you have hided earlier
}

// now this is the main function
function _setLookup(typeName, lookupFieldName, typeValue) {
var defaultViewId = Xrm.Page.getControl(lookupFieldName).getDefaultView();

if (typeName != null) {
// use randomly generated GUID Id for our new view
var viewId = "{1DFB2B35-B07C-44D1-868D-258DEEAB88E2}";
var entityName = "new_childentity";

// give the custom view a name
var viewDisplayName = "Polyclinic Directory for " + typeValue + "";

var fetchXml = "<fetch version='1.0' output-format='xml-platform' mapping='logical' distinct='false'>" +
"<entity name='new_childentity'>" +
"<attribute name='new_column1' />" +
"<attribute name='new_column2' />" +
"<attribute name='createdon' />" +
"<order attribute='new_column1' descending='false' />" +
"<filter type='and'>" +
"<condition attribute='new_conditionaloptionset' operator='eq' value='" + typeName + "' />" +
"<condition attribute='statecode' operator='eq' value='0' />" +
"</filter>" +
"</entity>" +
"</fetch>";

// build Grid Layout
var layoutXml = "<grid name='resultset' " +
"object='object_type' " +
"jump='new_childentityid' " +
"select='1' " +
"icon='1' " +
"preview='1'>" +
"<row name='result' " +
"id='new_childentityid'>" +
"<cell name='new_column1' " +
"width='200' />" +
"<cell name='new_column2' " +
"width='250' />" +
"<cell name='createdon' " +
"width='250' />" +
"</row>" +
"</grid>";

// add the Custom View to the indicated [lookupFieldName] Control
Xrm.Page.getControl(lookupFieldName).addCustomView(viewId, entityName, viewDisplayName, fetchXml, layoutXml, true);
}
else {
// no Account selected, reset Contact Lookup View to the default view such that all Contacts are displayed for selection
Xrm.Page.getControl(lookupFieldName).setDefaultView(defaultViewId);
}
}

Enable and disable user in MS CRM 4.0 or 2011

i was in a need to enable some users, who were diabled.
I tried to use CRM OTB, but it did not work, i got some SQL error message.
SO i did d dirty job, did it by using DB query and OTB use throw UI.

fire the query in ur DB
step 1
Select SystemUserId,IsDisabled from systemuser Where domainName ='<domain>\<loginName>'

collect the GUID from here
Step 2
Update SystemUser set IsDisabled = 0 Where SystemUserId = '<GUID from above query>'
Step 3
Now login to CRM with admin,
find the user in enabled list, just disabled it and again enable it.

Done.

MS CRM 2011 installation issue on shared server for DB and Application

I just faced a shocked situation.
i had one MS CRM 2011 installation in two servers say S_App1(application installed) and S_DB1(SQL installed).This was dev server suppose.
This works fine.
Next i had to install one instance for UAT.
here i used the S_App1 for DataBase instance.
SO i installed in two servers say S_App2(application installed) and S_App1(SQL installed, previously application installed server).

When i install "SetupSrsDataConnector" in S_App1 for UAT installation, inteligently the installation process took the application as the current server means S_App1.

SO a very crucial situation, i got the SQL error, even unable to login.
i saw in deplyoment manager, Application and DB were pointing to the same S_App1 server and my organization was in pending status. but the default org was fine , still it was not accesible.

Work around
What i did is, it strikes to my mind about the registry keys.
I just run the regedit and went to MSCRM under HKEY_LOCAL_MACHINE -> SOFTWARE -> MICROSOFT .
find the configdb, i saw the db was refering to S_App1, so i changed to S_DB1, then restarted the system.
It just wporked fine.

Oho.....

Wednesday, July 20, 2011

How to write Javascript on event of ribbon buttons ms cmr 2011

its very required things to write some JS code in the buttons of ribbon in ms crm 2011.
very simple to do so.
1. export your entity(with ISV if u hv migrated from 4.0)
2. find the control you are looking for and get the ID, suppose its Mscrm.Isv.new_netityname.Form.Group1.Control0
3. then go to CommandDefinitions section and add a CommandDefinition with the rule and actionas follows
<CommandDefinition Id="Mscrm.Isv.new_entityname.Form.Group1.Control0">
<EnableRules />
<DisplayRules>
<DisplayRule Id="Mscrm.Isv.new_entityname.Form.Group1.Control0" />
</DisplayRules>
<Actions>
<JavaScriptFunction FunctionName="Mscrm_Isv_new_entityname_Form_Group1_Control0_2" Library="$Webresource:new_entityname_ribbon.js" />
</Actions>
</CommandDefinition>
4. Now in the webresources you can get the file new_entityname_ribbon.js and create a function Mscrm_Isv_new_entityname_Form_Group1_Control0_2, then you can write your logic and can call other functions from ouside JS file.

hope this will help.
you can find the solutions form MS site also MS ribbon

SQL Generic Error, MS CRM 2011 or MS CRM 4.0

While migrating from MS CRM 4.0 to MS CRM 2011, i just found a strange error.
From my custom code i was not able to create a custom entity where as i was able to update the same and create and update others.
after lots of investigation i found, there was a trigger, which was causing the error.
I tried to check the permission, if any plugin and plugin access permission.
Even form crm also i was unable to create.
So make sure even if everything is fine, there may be some custom trigger or SPs, which can cause issues.

hope this can help some one in avery bad situation coz, this is very difficult to catch.

Tuesday, July 19, 2011

MS CRM 2011 roll ups and checking the vesrion of MS CRM 2011

MS has released rollups as follows
1. roll up 1
    this release have a delay declared by MS.
    this roll up contains most of the feautres from roll up 9, as 9 has a delay for release.
    Big Update Rollup 10 news!
  • More Windows 8 / Internet Explorer 10 compatibility
  • Many performance and stability-related fixes, including fixes to the CRM Client for Microsoft Outlook
  • Contains all fixes originally scheduled for release via Update Rollup 9
  • Quick Find performance optimizations and EnableRetrieveMultipleOptimization SQL query performance optimizations
11. roll up 11
Microsoft has released Update Rollup 11. This is a tested, cumulative set of updates for Microsoft Dynamics CRM 2011. It includes performance enhancements that are packaged together for easy deployment.
12. roll up 12

mainly the browser compatibility
Browser flexibility will apply to all functions within Microsoft Dynamics CRM for both end users and administrators alike. The list of devices, operating systems and specific browser versions is detailed in the table below.
PlatformInternet ExplorerFirefoxChromeSafari
Windows XPVersion 8Version 16+Version 22+Not Supported
Windows VistaVersion 8 and 9Version 16+Version 22+Not Supported
Windows 7Version 9 and 10Version 16+Version 22+Not Supported
Windows 8Version 10Version 16+Version 22+Not Supported
Apple OS X 10.7 (Lion)Not SupportedNot SupportedNot SupportedVersion 6+
Apple OS X 10.8 (Mountain Lion)Not SupportedNot SupportedNot SupportedVersion 6+
Apple iOS (iPad)Not ApplicableNot ApplicableNot ApplicableSupported
13. roll up 13
14. roll up 14
15. roll up 15
16. roll up 16
    hope this will help.
will update here as per the update roll ups

How to get the Rollup version....
 
to get the current version of the rollups installed in ur MS CRM 2011 instance is as follows
To determine your current build number from the Internet Explorer client, simply:
  1. Login to your CRM 2011 website
  2. Click on the File tab on top left
  3. Navigate to Help
  4. Click on “About Microsoft Dynamics CRM” (see d attached image)
After clicking that it will popup a screen as attached which contains the version number as highlighted. so by matching the number u can know the rollup.
To determine your current build number from the Outlook CRM client:
  1. Open Outlook with the CRM Client installed
  2. Click on the File tab
  3. Click on the CRM side tab
  4. Click on the “About Microsoft Dynamics CRM” button as in image
the versions are as follows as per the rollups

RTM
5.0.9688.583
Update Rollup 1
5.0.9688.1045
Update Rollup 2
5.0.9688.1155
Update Rollup 3
5.0.9688.1244
Update Rollup 4
5.0.9688.1450
Update Rollup 5
5.0.9688.1533
Update Rollup 6
5.0.9690.1992
Update Rollup 7
5.0.9690.2165
Update Rollup 8
5.0.9690.2243
Update Rollup 9
late release or may not come to market
Update Rollup 10
5.0.9690.2730
Update Rollup 11
5.0. 9690.2835

Monday, July 18, 2011

Ribbon Button Hide Error Dependency Error ms crm 2011

If you are using the Ribbon HideAction to hide some buttons, group of buttons or tab etc, then u can get the IDs by using the tool.
Make sure the the Location attribute value is case sensitive.
<blockquote><RibbonDiffXml>
<CustomActions>
//if i will use NEW inplace of new, it will give me the above error
<HideCustomAction Location="Mscrm.HomepageGrid.<strong>new</strong>_futurepatient.MainTab.Workflow" HideActionId="Mscrm.HomepageGrid.new_futurepatient.MainTab.Workflow" />
<HideCustomAction Location="Mscrm.HomepageGrid.new_futurepatient.RunReport" HideActionId="Mscrm.HomepageGrid.new_futurepatient.RunReport" />
<HideCustomAction Location="Mscrm.HomepageGrid.new_futurepatient.Import" HideActionId="Mscrm.HomepageGrid.new_futurepatient.Import" />
</CustomActions></blockquote>

Hope this will help anyone, i hv faced the same issue, and resolved in this way.

Sunday, July 17, 2011

Automatic creation of entity and attribute in MS CRM 2011, awesome feature, am impressed

Hi All,

There is an awesome feature in MS CRM 2011, which will be creating entiy and attributes automatically while importing the data.
So if you ahve to create any entities with attributes, then just create a CSV file with atleast one record and upload it.
Name the file as per your Entity Name.
Suppose my file name is Test and the columns are as follows.save it as test.csv.
name,age,sex
aa,12,m
bb,45,f

Now go to MSCRM 2011
Settings -> System -> Data Management and click Imports from the right side
Now click Import from the Ribbon
Browse and Select the Test.csv and click Next
Then Click NExt
Then Click Next
Here is the page to name and map the fields.
Make sure you are mapping the name with the Name provided by the system.

Do this for all the fields and click next.
then slect allow duplicate or not, also the records you want to assign etc.
Then click Submit.
Not go to the Customization and customize the Form.
You will have the records in place also.
So its really Koooolll....
This has some limitations, still this can help you for any quick PoC or prototype else in design phase to put the screen shots :P

how to custom a due date (or any date) on the records of the home grid in MS CRM 4.0 also in 2011

Suppose you have a field on an entity. and you want to populate the records by highlighting that field value on basis of some logic.
In my case am considering the Due Date of an entity, if the due date is earlier than today , then the value in the Grid will be red.

1st Step
include the JS file in the HomePage.aspx in the _root/ of the installed MS CRM.
in that include the code
function window.onload()
{
updateDueDate();
}
2nd step
wrtite the JS code

//coloring the due date and also doing the alternate grid clor
function colorizedduedate(mytable, mycolumn) {
var loTable=document.getElementById(mytable);
var j
var datetoday = new Date;
var datedue = new Date;
var dateduestr
var datetodaystr
var colPatient= crmGrid.InnerGrid.FindColumnIndex("<id of the primary attribute for that entity, fo me its new_patientid>");

var month = datetoday.getMonth() + 1;
var day = datetoday.getDate();
var year = datetoday.getFullYear();

if (month<10) {
month = '0' + month;
}

if (day<10) {
day = '0' + day;
}
if (loTable.rows.length < 1)
{
return;
}
for (var j = 0; j < loTable.rows.length; j++) {
x=loTable.rows[j].cells;
if (typeof(x[mycolumn]) =="undefined") { return;}
dateduestr=x[mycolumn].innerHTML;
if (typeof(dateduestr) =="undefined") { return;}
if (dateduestr != '')
{
dateduestr = dateduestr.replace('<NOBR>','');
dateduestr = dateduestr.replace('<NOBR class=datetime>','');
dateduestr = dateduestr.replace('</NOBR>','')

var datearr = dateduestr.split("/"); //dd/mm/yyyy to mm/dd/yyyy
dateduestr = datearr[1]+ "/" + datearr[0] + "/" + datearr[2];

var datearr2 = dateduestr.split(" "); //remove time
datedue = new Date(dateduestr);
if (datetoday > datedue)
{
x[mycolumn].innerHTML='<span style=\'color:#FF0000\'>'+x[mycolumn].innerHTML+'</span>';
}
}

var cols = loTable.rows[j].getElementsByTagName("NOBR");

if ((j % 2) == 0) {
loTable.rows[j].style.backgroundColor = "#EEEEEE";
grid.childNodes[i].colourised = true;
}
else {
}

}
}

//only coloring alternate colors to the grid
function colorizedotherentity(mytable) {
var loTable = document.getElementById(mytable);
var j

var grid = document.getElementById(mytable).lastChild;
for (var i = 0; i < grid.childNodes.length; i++)
{
if ((i % 2) == 0) {
grid.childNodes[i].style.backgroundColor = "#EEEEEE";
grid.childNodes[i].colourised = true;
}
else {

}
}
}


function CheckTaskListMenus() {
if (_currentTypeCode == <check the objecttype code as account is 1> ) {
//Hide the filter (A,B..Z) at the bottom of the grid
document.getElementById("crmGrid_JumpBar").style.display = "none";

if (document.getElementById('_MBdoActioncrmGrid10051assign') != null) {
document.getElementById('_MBdoActioncrmGrid10051assign').style.display = "none";
}

var colduedate = crmGrid.InnerGrid.FindColumnIndex("new_datedue");
colorizedduedate("gridBodyTable", colduedate);

}
else {
colorizedotherentity("gridBodyTable");
}
}
//main function which will be called from the HomePage.aspx
function updateDueDate(){
CheckTaskListMenus();
crmGrid.attachEvent("onrefresh", OnGridRefreshX);
}

hope this will help.

ISV Java script Code from M SCRM 4.0 to MS CRM 2011

As we know that there is know ISV concept in MS CRM 2011, where as we got ribbon concept here.
So while doing upgration from 4.0 to 2011, the JS code we have written in ISV will be going to 2011 to ribbon xml file.
How you can find the things in 2011.
the starting point is , just find the new_<entity_name>_ribbon.js in your web resources.
In 4.0 ISV we can write JS codes in the maingrid as well in the form level grid also.Also we can refer the out side JS files in both.
If so, then the form level JS can refer the functions to the out side JS files, onload of it.
But from home grid it will not fetch, so we need to call the function itself from the new_<entity_name>_ribbon.js.
Hipe this will help a bit for the ISV champs.

Thursday, July 14, 2011

How to hide tabs,groups,buttons,SplitButton, from the ribbon(main grid,form level) in MS CRM 2011

We may have requirement for hiding the tabs, groups or buttons or SplitButton from the ribbons(new concept in ms crm 2011) on main grid or else on form also it cna be on othe rgrids like the associated view etc.
maingrid looks like



form grid looks like

main thig to hide the ribbons is to get the id to be hidden.
to get it use the tool from “\sdk\samplecode\cs\client\ribbon\exportribbonxml" if you ahve installed. else you can get it from MS CRM 2011 SDK.
build that solution by using VS 2010. Run it. it will ask you the server url with port number, credentials and the Org name.
after that it will create the ribbonxml file into c:/user/ExportRibbonXML\ExportedRibbonXML folder. create this folder and give access to that folder. else it will give some access right error.
It will create the files like entitynameRibbon.xml.
Open that file to get the proper ID taht you want to hide.
Its bit tricky to get.
for main grid the part is
like that the form level grid xml will be

now take ids from the ribbonxml files.

Import the entities you want to customize the ribbon by creating a solution.
unzip it and open the customization.xml file.
search the CustomActions node under RibbonDiffXml node.
then put the following tag <HideCustomAction Location="ID.you.got.from the.above.observation" HideActionId="LOcation_values_Earlier.HideAction" />

Like this you can add the tab_id, group_id and also the button_ids and you can hide the things.

am tired. ;)