Posts

search text in Stored Procedures

Do you want to find any text in Stored Procedures in SQL Server Database ? "select * from INFORMATION_SCHEMA.ROUTINES" returns Procedure,Function exist in specific database. You will see objects and details in columns.

create connections between two entities with Late Binding in Microsoft CRM 2011

Hi, I would like to share benefits of connections in Microsoft CRM 2011 and how to build connection in 2 Entities by LateBinding. Connected entities may be both Custom or System. here is how the SDK describes the benefits of Connections Connections  provide the following capabilities: An easy and flexible way to make a connection between two records of most Microsoft Dynamics CRM entity types. All customizable business and custom entities can be enabled for connections. An option to add useful information, such as description of the connection and the duration. An ability to create connection roles that describe the relationship between the two records, such as a relationship between a doctor and a patient, or a manager and an employee. A quick way to create multiple connections and roles for a particular record. For example, a contact may have many relationships with other contacts, accounts or contracts. In each relationship a contact may play a different role. Informa

make relationship in Microsoft CRM SDK

If you want to make 1 to N relation between two entities in CRM. You have couple ways.I would like to share two of them. First of all; You can make relation after creating new record .                         CustomEntityInCRM1 referrerEntity = ...//retrieve data;                         CustomEntityInCRM2 referencedEntity = ...//retrieve data;                         Relationship rs = new Relationship(" ");                         EntityCollection relatedEntities = new EntityCollection                         {                             EntityName = referencedEntity.LogicalName,                             Entities = {                                 referencedEntity                             }                         };                         referrerEntity.RelatedEntities.Add(rs, referencedEntity);                         _serviceProxy.Update(referrerEntity); or you can retrieve two of them and make connection (prevent 'The collection is re

Everything about Log4Net

log4net is a library to help the programmer output log statements to a variety of output targets by Apache Software Foundation (official page = http://logging.apache.org/log4net/).You can also download either source code or compiled library. It is compatible for .net project(s) and need to know couple basic things to use in your project easily. First of all, There is a configuration you have to set before adding into your project. Here is a sample about inserting log into a given file. app.config file;    <!--Start Code-->       <?xml version="1.0" encoding="utf-8" ?>          <configuration>             <configSections>                   <section name="log4net"                   type="log4net.Config.Log4NetConfigurationSectionHandler, log4net"/>                </configSections>          <startup>             <supportedRuntime version="v4.0" sku=".NETFramework,

how to call any Web Resource image in your web page from CRM 2011

Hi, You can call Web Resource from crm easy. Just add; http(s)://CRM_url:(port)/WebResources/nameOfTheWebResource or /WebResources/nameOfTheWebResource in CRM do not use "Display Name" and "extension". Good Luck,

retrieve,update,assign,create related object records in Microsoft CRM 2011

Hi, here is a sample of how to obtain records from CRM. You need prebuild classes from current Microsoft CRM 2011 deployment.to do this use crmsvcutil.exe which comes from CRM SDK (...SDK\bin\). Built Class includes both standart Entities and Custom Entities. Usage : crmsvcutil.exe /url:http(s)://crm.???.com(:444)/organization_name/XRMServices/2011/Organization.svc /out:" \OrganizationCodes.cs " /username:muhammet.atalay /password:ILoveCrm /domain:??? /serviceContextName:...ServiceContext Do not forget to add OrganizationCodes.cs into your project. ServiceContext uses as below while retrieving any records via LinQ. ServiceContext context;            context = new ServiceContext((IOrganizationService)_serviceProxy); List contacts = context.ContactSet.Where(c => c.fieldName == criteria).ToList(); you can create a record as follow; Contact conn = new Contact(); set fields _serviceProxy.Create(booking); assign record to a user while creating record exampl

Credentials,tokens sample in Microsoft CRM 2011 from SDK by Late Bind Approach with IFDS deployment

Hi, First of all, Download Microsoft CRM 2011 SDK from Microsoft Web Site.Please ask google for exact URLs. do not forget adding Microsoft.xrm.sdk library from SDKs. IServiceManagement orgServiceManagement = ServiceConfigurationFactory.CreateManagement ( new Uri("http(s)://crm.???.com(:444)/organization_name/XRMServices/2011/Organization.svc")); Set the credentials. AuthenticationCredentials authCredentials = new AuthenticationCredentials(); authCredentials.ClientCredentials = new ClientCredentials(); authCredentials.ClientCredentials.UserName.UserName = "muhammet.atalay"; authCredentials.ClientCredentials.UserName.Password = "I Love CRM"; AuthenticationCredentials tokenCredentials = orgServiceManagement.Authenticate(authCredentials); Retrieve Token SecurityTokenResponse orgTokenResponse = null; if (tokenCredentials != null)