Quantcast
Channel: CRM Development forum
Viewing all articles
Browse latest Browse all 9244

MS CRM 2011 ONLINE - Setting default product to order product

$
0
0

I am trying to set the default product for the order product. I use script below on the form's onLoad event.

function SetDef(){
lookup = Xrm.Page.getAttribute('productid').getValue();
if (lookup == null) {
Xrm.Page.getAttribute('productid').setValue([{id: '31F65B93-30ED-E211-9B99-EE3A97CBB23B', name: 'Service', entityType: 'typeproduct'}]);
}
}

I only get this:

I have no idea what is wrong. The same script worked for default customer for order form.


Viewing all articles
Browse latest Browse all 9244

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>