CRM 2011 – What happens to revised quotes

A customer asked me what happens when they revise a quote and can they view the historical quotes.

Now I know the process of quotes is you create a draft, then activate the quote.

if the quote changes then revised the quote, this increments the revision number by one.

 

but what happens to the revised quotes?

where do they go?

how do you view them?

 

I had to tell the customer that I didn’t know but I had an idea the quotes were closed and the revised quote was a new quote with the same ID and a revision number incremented by one.

 

As it happens that is what happens.  For a quote you can only have one quote with the status of draft/active.  Any other quotes with the same quote id will be made inactive with a status of closed.

You can view the quote history by doing an advanced find and choosing where quote id = the quote id.  This will then show you all of the quotes.

 

I’m not sure what will happen if you turned on auditing for quotes.  It depends on how quotes actually work.  When you revised the quote does it create an old quote and close it, creating a snapshot of the quote.  Or does it close the existing quote and create a new one.

 

CRM 2011 – Javascript to update variables only on Create

[tweetmeme source=”BenHosk” only_single=false]

I had an interesting problem, I wanted to default a drop downlist on an onload event but only if the user was creating a new contact.

The reason I wanted it only for a create is because it would overwrite the value of the variable if I had it on the onload event of the contact because my drop down list had two values and no unassigned value.

http://msdn.microsoft.com/en-us/library/0375b206-d2bf-4034-a41d-fb476ecb4438#BKMK_getFormType

getFormType

Indicates the form context for the record.

Xrm.Page.ui.getFormType()
Return Value
Type: Number
The following table lists the form types that correspond to the return value.
Value Form Type
0 Undefined
1 Create
2 Update
3 Read Only
4 Disabled
5 Quick Create (Deprecated)
6 Bulk Edit

Example: The SDK.UISamples.getFormType alerts the user with a different message depending on the current form type.

getFormType: function () {

 var FORM_TYPE_CREATE = 1;
 var FORM_TYPE_UPDATE = 2;
 var FORM_TYPE_READ_ONLY = 3;
 var FORM_TYPE_DISABLED = 4;
 var FORM_TYPE_QUICK_CREATE = 5;
 var FORM_TYPE_BULK_EDIT = 6;

 var formType = Xrm.Page.ui.getFormType();
 if (formType == FORM_TYPE_CREATE) {
  alert("This record has not yet been created.");
 }
 else {
  alert("This record exists in the database.");
 }
},

CRM 2011 – Add CRM Web site to Trusted Site message

For some reason I was suddenly getting a message saying CRM uses lots of scripts and I need to add the CRM website to my trusted zones.

This is the error message

I have no idea why this suddenly started appearing but when I added the url to the trusted sites it still didn’t work.

Interestingly this happened also for my CRM 4 links and I had to add the url to the trusted sites as well.  So you definitely have to do both parts to get it working.