Posts

Showing posts from 2010

Using Read-only versus const

There are Two difference versions of constants in C#: the Const keyword is used for compile –time constants read only keyword is used for runtime constants. The main issue with const is that it's evaluated at compile-time, which means if it's changed at a later date; you have to not only recompile that application, but all applications that reference that application. In contrast, read -only is evaluated at run-time providing you a lot more flexibility. An overview of differences between const and read-only in c#      Const Read only Cont be static Can be either instance-level or static Value is evaluated at compile time The value is evaluated at run time. It is initialized at declaration only It can be initialized in declaration or by code in the code constructor .therefore read only fields have difference values depending on constructor used.   So, const should really only be used for logical, real-world constants such as days of week, numeric Constants, etc. as for as perfo

Setting Required Field Mark on demand in MS CRM 4.0

In one of our projects we came across the requirement to set required field mark based on change in pick list. To full fill the requirement I find a JavaScript method supports in MS CRM 4.0. Syntax: crmForm.SetFieldReqLevel(" field name ", value );     Fields Name is name of the field which you want place as required.     Value represents is this field marked as required or not.      1 for required field mark      0 for not required field mark Example for required field mark : crmForm.SetFieldReqLevel("pos_datetimeoftxn", 1); Example for not required field mark : crmForm.SetFieldReqLevel("pos_datetimeoftxn", 0);  

MS CRM 4.0 Relationship Mappings Error

Image
Whenever relationship is deleted but relationship attribute is used in another relationship mappings. In that case if you click on mappings you will get below error message. Cause: attribute is deleted but attribute is used in attribute mappings. In MS CRM attribute relationship mappings are saved in following tables E ntityMapBase AttributeMapBase Identify the mapping record in EntityMapBase Table. Take the GUID of that record and find the related attribue records in AttributeMapTable select * from dbo . AttributeMapBase where EntityMapId = 'place your relationship record GUID' update the your deleted attribute records DeletionStateCode with 2.

Web.Config Settings for Custom Aspx Application integration with MS CRM 4.0

MS CRM 4.0 implements the http models for multi tendency. We need to remove these models for our custom aspx application. < httpModules > < remove name = "CrmAuthentication"/> < remove name = "MapOrg"/> </ httpModules > Or < httpModules > < Clear /> </ httpModules > Another Way to read your Owen App Settings is using System.Configuration; using System.Web.Configuration;      // ... Configuration configuration = WebConfigurationManager .OpenWebConfiguration( "/ISV/MyApp" ); string myParameter = configuration.AppSettings.Settings[ "MyParameter" ].Value;

Microsoft Dynamics CRM menus overlap when you use Internet Explorer 8 with Windows 7

When you use the Windows 7 Operating System and Internet Explorer 8, the Internet Explorer windows may overlap.  This causes some Microsoft Dynamics CRM options to not be visible. To resolve such issue, add all add all relevant Microsoft Dynamics CRM URLs to the Local Intranet sites in Internet Explorer using the following steps: Click Tools, and then click Internet Options. Click the Security tab, click Local Intranet, and then click Sites. Click the Advanced button, and then add the following URLs: https://*.crm.dynamics.com https://login.live.com Click Close, click OK, and then click OK. Restart Internet Explorer.  

System Jobs all ways going to waiting status

System Jobs that are triggered in Microsoft Dynamics CRM are not processed and remain in a waiting state. This problem occurs because of the following cause: Cause : The Async service cannot connect to the server. By default, the AsyncSDKRootDomain field in the DeploymentProperties table is left blank. This means, when the Async service tries to connect to the server, it uses the loopback address of 127.0.0.1. However, the CRM Web site is now using an assigned IP address, the Async service cannot connect to the server. To resolve this problem, follow these steps: Make sure that a HOST (A) record has been created in DNS and point to the IP address assigned to the CRM Web site. Download the Deployment Configuration tool. For more information, click the following article number to view the article in the Microsoft Knowledge Base:   (http://support.microsoft.com/kb/949079/ ) How to use the Microsoft Dynamics CRM Deployment Configuration tool for Microsoft Dynamics CRM 4.0 Extract the Deplo

Redeploy the Microsoft Dynamics CRM deployment that includes the Microsoft Dynamics CRM Server within the same domain or to another domain.

Back up the Organization _MSCRM databases. To do this, follow these steps: On the computer that is running SQL Server, click Start , point to All Programs , point to Microsoft SQL Server 2005 , and then click SQL Server Management Studio . Expand Databases , right-click the Organization _MSCRM database, point to Tasks , and then click Back Up . Under Destination , add the location to save the backup file, and then click OK . Repeat steps 1b and 1c for any other Organization _MSCRM database that must be moved. Install Microsoft Dynamics CRM 4.0 on the new computer that will run Microsoft Dynamics CRM Server. Note When you are prompted to enter the organization name, use a name that differs from the original organization name. You will import the old organization into the new installation. Therefore, you do not want the installation process to create a new organization that has the same name. Restore the Organization _MSCRM databases on the new computer that is running SQL Server. To d

Move the Microsoft Dynamics CRM databases to another SQL Server and SQL Server Reporting Services server in the same domain, and leave the Microsoft Dynamics CRM Server on the existing server

Back up the Organization _MSCRM database and the MSCRM_Config database. To do this, follow these steps: On the computer that is running SQL Server, click Start , point to All Programs , point to Microsoft SQL Server 2005 , and then click SQL Server Management Studio . Expand Databases , right-click the Organization _MSCRM database, point to Tasks , and then click Back Up . Under Destination , add the location to save the backup file, and then click OK . Repeat steps 1b and 1c for the MSCRM_Config database. Note If you must move more than one organization, repeat steps 1a-1d for each organization database. Restore the Organization _MSCRM database and the MSCRM_Config database on the new computer that is running SQL Server. To do this, follow these steps: On the new computer, click Start , point to All Programs , point to Microsoft SQL Server 2005 , and then click SQL Server Management Studio . Right-click Databases , and then click Restore Database . Under Destination to restore , typ