I need help with variable scope for XRM C# code
On the Catch section of a Try-Catch block I need to save a value which is declared in a foreach loop (var crmAccount). I have to declare crmAccount outside the Try to be able to use it in the...
View ArticleRetrieve line breaks from ntext field
In my asp.net application I need to retrieve ntext fields with line breaks. How can I do this? I know I can insert with .Replace(Environment.NewLine, "<br />") and then receive line breaks back,...
View ArticleLock field on initial save
Hi All,My client would like a couple of fields on the opportunity form that lock once they have been filled in and the opportunity saved for the first time, after this they should stay locked.Is there...
View ArticleAdd week and year to opportunity
Hi All,My client would like two fields adding to the opportunities form, one for the week the opportunity was created and the other for the year the opportunity was created. They should be locked and...
View ArticlePlugin Image MessagePropertyName
Can anyone describe this attribute? Why on an update event is it a "Target" but on a create event it can't be "Target"? Is there anything wrong with this arrangement?<Image EntityAlias="PostImage"...
View ArticleRollup 12 - problem with web resources and jquery
Hi all,Before Rollup 12, the main form iframe of an entity added js script references in the <head> section. After RU12 the scripts are added in the body and scripts aren't always executed in...
View ArticleHow to set an integer field to null through soap API
I am trying to set an integer field to null through soap API. However, I always get errors.With <b:value i:type="c:int" xmlns:c="http://www.w3.org/2001/XMLSchema"></b:value>, I got the...
View ArticleCRM 2011 : Sub-grid data load using custom fetchXML on contact
Hello Friends,I want to show all the campaign response created against particular contact in sub-grid on contact form.I have visited many articled which all are just specifying a single possible way to...
View ArticleCreate instance of OrganizationService from Console
Hi,I am trying to create a Console Application Test Harness for my Custom Workflow Activity. (As it is a console, I dont have a CodeActivityContext.)So I want to create an instance of a...
View ArticleHow to set Default value for Time in Date and Time Field
Hi ,Could someone pls tell me how can i set default value for time in Date and Time Field.
View Articleupdate originatingleadid
I'm trying to update an account with an originating lead (this is a data migration deal so I am not in normal channels.) I've tried this and nothing happens. I'm wondering if it is possible or if I'm...
View ArticleFow Hide Field based on checkbox selection
Hi, please forgive my ignorance, but I am new to CRM 2011.I would like to simply show or hide a field based on whether a checkbox is selected or not.I have research the following code, but I still...
View ArticleHow to download an attachment from the context.InputParameters - help!!
Hi Guys.Ive spent more than 4 hours trying to figure out the correct way for downloading a attachment from a "DeliverIncoming" message of an email. I wanted to trap some events from inside the incoming...
View ArticleMS CRM 2011 outlook client Unable to get Value of property 'getFormType'
Hi All,I am facing a strange problem where when I access MS CRM 2011 from within outlook client (2010 on-line mode) andopen an existing form (for example opportunity) which uses getFormType function on...
View ArticleCRM 2011 field On Change Event Javascript getting Value using...
Hi I am experiencing a strange behaviour when I try to get a field value Xrm.Page.getAttribute(totalAmountFieldName).getValue(); on change. It gives the previous value not the current changed value.but...
View ArticleDecimal Place on Quantity field in Order Product form
Hi All,How to set the quantity field to no decimal places? I had change the field precision to 0, but after tab off the field, there is 5 decimal places display.Thanks.Regard,Teh
View ArticleConfused on GUIDs and how they work
I have a lookup field called "Sales Contact", but I am confused about the GUID retrieved. When I lookup a record and use the following line:var sales_contact =...
View ArticleCreate related entities with rest endpoint
Hi,I'm trying to use the rest create to create a custom entity and associated entities similar to the way this sample is doing from the MS website..var account = {}; account.Name = "Test Account Name";...
View ArticlePlugins, Messages, and StateCode access
This is in a 2011 CRM Online instance.We currently have post-operation plugins registered on the QueueItem Entity for the SetState and SetStateDynamicEntity messages. When the related Entity's state,...
View ArticleDifficulty adding in another inner join on my sql statement
HiI have created the following sql statement (notice the commented code)How do I incorporate the 2nd inner join in to the sql statement.Sorry, just a newbie SELECT CON.new_VIPContactType,...
View Article