Answered by:
update picklist to null

Question
-
hi all
im having a problem updating picklist to null after the field is alredy fill with a value
i tried this
<instance.customizeed field name> = null;
crmservice.update(instance)
the output of this is that field isn't updatedSunday, May 10, 2009 7:00 AM
Answers
-
Here is an example:
Picklist list = new Picklist();
list.IsNull = true;
list.IsNullSpecified = true;
Blog: http://mscrm4ever.blogspot.com/ * Website: http://gicrm.upsite.co.il/- Marked as answer by guymalka Sunday, May 10, 2009 10:23 AM
Sunday, May 10, 2009 7:23 AM -
Hi guymalka,
when you set the field value to null than this means that you don't want to update this field.
To bin in Adis posting in your code you have to write this code:
<instance.customized field name> = new Picklist();
<instance.customized field name>.IsNull = true;
<instance.customized field name>.IsNullSpecified = true;
crmservice.update(instance)
Best regards,
Jürgen
Jürgen Beck
Dipl. Kfm./Wirtschaftsinformatik
MVP, MCSD.NET, MCITP DBA, MCDBA, MCSE
Microsoft Certified Business Management Solutions Professional
Microsoft Certified CRM Developer
Microsoft Certified Trainer
ComBeck IT Services & Business Solutions
Microsoft Gold Certified Partner
Microsoft Small Business Specialist
Developing & Supporting Business Applications from small business to big enterprises covering scores of sectors
http://www.combeck.de
- Proposed as answer by JuergenBeckModerator Sunday, May 10, 2009 10:20 AM
- Marked as answer by JuergenBeckModerator Saturday, May 16, 2009 6:57 PM
Sunday, May 10, 2009 10:20 AMModerator
All replies
-
Here is an example:
Picklist list = new Picklist();
list.IsNull = true;
list.IsNullSpecified = true;
Blog: http://mscrm4ever.blogspot.com/ * Website: http://gicrm.upsite.co.il/- Marked as answer by guymalka Sunday, May 10, 2009 10:23 AM
Sunday, May 10, 2009 7:23 AM -
Hi guymalka,
when you set the field value to null than this means that you don't want to update this field.
To bin in Adis posting in your code you have to write this code:
<instance.customized field name> = new Picklist();
<instance.customized field name>.IsNull = true;
<instance.customized field name>.IsNullSpecified = true;
crmservice.update(instance)
Best regards,
Jürgen
Jürgen Beck
Dipl. Kfm./Wirtschaftsinformatik
MVP, MCSD.NET, MCITP DBA, MCDBA, MCSE
Microsoft Certified Business Management Solutions Professional
Microsoft Certified CRM Developer
Microsoft Certified Trainer
ComBeck IT Services & Business Solutions
Microsoft Gold Certified Partner
Microsoft Small Business Specialist
Developing & Supporting Business Applications from small business to big enterprises covering scores of sectors
http://www.combeck.de
- Proposed as answer by JuergenBeckModerator Sunday, May 10, 2009 10:20 AM
- Marked as answer by JuergenBeckModerator Saturday, May 16, 2009 6:57 PM
Sunday, May 10, 2009 10:20 AMModerator