Posts

CRM Explorer/Tools missing from Visual Studio 2010

Image
if you ever find the Dynamics CRM 2011 Explorer / Tools options missing from within Visual Studio 2010 .... ... check prerequisites are installed:- 1. Visual Studio 2010 SP1 2. Silverlight 4 3. Windows Identity Foundation 4. CRM Developer Tools (found within the CRM SDK, Tools folder) Then check that the following is mentioned in your solution file (if you open the .sln file in a text editor): Save and reload the solution in Visual Studio 2010.  Do not append 'SolutionIsBoundToCrm = True' line to the below if you meet in your solution file. GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection good luck,

Exception caught instantiating TERADATA report server extension SQL Reporting Services

Hi, If you face an error in Reporting Services Log File (C:\Program Files\Microsoft SQL Server\MSRSxx_xx.MSSQLSERVER\Reporting Services\LogFiles) such as : extensionfactory!ReportServer_0-1!ea4!03/26/2013-08:20:15:: e ERROR: Exception caught instantiating TERADATA report server extension:  System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.  ---> System.IO.FileNotFoundException: Could not load file or assembly 'Teradata.Client.Provider, Version=12.0.0.0, Culture=neutral, PublicKeyToken=76b417ee2e04956c' or one of its dependencies. The system cannot find the file specified. File name: 'Teradata.Client.Provider, Version=12.0.0.0, Culture=neutral, PublicKeyToken=76b417ee2e04956c'    at System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)    at System.Refl

flip rows to column in SQL Server

Below is a table that i use in the example; AttendeeName GroupName QuestionName AnswerName QuestionId Value Result Order SurveyId AnswerId Ahmet Ege Kisisel Bilgiler Askerlik Yaptiniz mi? (Q1) Evet (A1) 1 1 5 1 11 4 Ahmet Ege Kisisel Bilgiler Evli misiniz? (Q2) Hayır (A2) 2 1 6 3 11 5 Ahmet Ege Kisisel Bilgiler Is ariyor musunuz? (Q3) Evet (A3) 3 1 1 2 11 7 and the result expectation is;

Get PickList value for Reports or other SQL statements

There is a table,'StringMap' which contains map of id with value. you can run any select statement against this table.'AttributeValue' takes key and 'value' takes value of the key.You should do some filter actions to focus on to the exact data that we may need so add 'ObjectTypeCode' as type code of Entity and 'AttributeName' as name of the field to the where statement. Example; SELECT AttributeValue,Value FROM StringMap WHERE ObjectTypeCode = '1' and AttributeName='customertypecode' Query will return CustomerTypeCode of Account. There is also alternate, if you do not know type code of the entity; FilteredViewName must be name of the entity with 'Filtered' prefix : Filtered+account. SELECT AttributeValue,Value FROM FilteredStringMap WHERE FilteredViewName= 'Filteredaccount' and AttributeName='customertypecode' query will return same result as above. good luck.

how to Filter lookup in CRM 2011 by javascript in Client Side.

You can set any lookup with custom view in client. Here is a simple javascript code build dfor CRM 2011.This code run in onLoad of  Response  Custom entity. relation of the entities EntA 1---N EntB 1---N EntC 1-- N EntD for the sample. Filter rule is; Lookup gets only selected EntAs for the EntD function onLoad() { //filter questions for the current EntC var EntCLookup = Xrm.Page.getAttribute("field of the EntityReference of EntC").getValue(); if (EntCLookup != null) { var EntCId = EntCLookup[0].id; var viewId = "{8F03FB3E-0EFF-4417-B704-80CE1711B8D2}";/static guid id.you can obtain by Visual Studio tool var entityName = "EntA"; var viewDisplayName = "EntA Filtered View by EntC"; var fetchXML = "<fetch version='1.0' output-format='xml-platform' mapping='logical' distinct='true'>" + "<entity name='EntA'>&q

how to serialize an object to XML, and vice versa

Hi, Here is code sample of Serializing and Deserializing.There is also some additional methods to convert Byte Array in the sample. i use serialize and deserialize actions by generic in C# private Byte[] StringToUTF8ByteArray(String pXmlString) { UTF8Encoding encoding = new UTF8Encoding(); //UTF8Encoding is under the System.Text namespace Byte[] byteArray = encoding.GetBytes(pXmlString); return byteArray; } private String UTF8ByteArrayToString(Byte[] characters) { UTF8Encoding encoding = new UTF8Encoding(); String constructedString = encoding.GetString(characters); return (constructedString); } private string Serialize(T request) { //MemoryStream is in System.IO //XMLSerializer is in System.Xml.Serialization using (MemoryStream memoryStream = new MemoryStream()) { XmlSerializer xs = new XmlSerializer(typeof(T)); XmlTextWriter

retrieve columns from LinkedEntities in Microsoft CRM 2011

Hi, You prepare QueryExpression and add some LinkedEntities then you want to retrieve fields from linked part.Just follow the sample;  QueryExpression query = new QueryExpression()                     {                                         ...                                         ...                     };                     FilterExpression filterTicket = new FilterExpression();                     ...                     query.Criteria = filterTicket;                     //all about ticket                     query.LinkEntities.Add(new LinkEntity("contact", "new_new_ticket_contact", "contactid", "contactid", JoinOperator.Inner));                     query.LinkEntities[0].EntityAlias = "contacttoticket"; add alias to reach the fields                     query.LinkEntities[0].Columns.AddColumn("new_ticketid"); add column names to the same level of LinkedEntity to obtain later...