November Happy Hour will be moved to Thursday December 5th.

Saving new EntityObjectProperty not working

Vote:
 

Hello!

I have added a Company property on the Contact Object in Commerce Manager, but i don-t get it to save!! whats wrong?

                    EntityObjectProperty EO = CustomerContact["company"] as EntityObjectProperty;
                    if (EO == null)
                    {
                        CustomerContact["company"] = new EntityObjectProperty("company",Company.Text);
                    }
                    else
                    {
                        CustomerContact.Properties["company"].Value = Company.Text;
                    }
					CustomerContact.SaveChanges();

 Ive also tried

 CustomerContact["company"] = Company.Text;

 

#57063
Feb 23, 2012 12:54
Vote:
 

oh sk*t, it is case sensitive, this is enough:

CustomerContact["Company"] = Company.Text;
#57067
Feb 23, 2012 14:56
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.