How To create add Note to Order Notes collection

Discussions related to custom development with Select.
Post Reply
oleksiy_tereshchenko
Posts: 8
Joined: Fri Oct 10, 2014 2:45 pm

How To create add Note to Order Notes collection

Post by oleksiy_tereshchenko »

Need help with solving following problem. Cannot find in documentation how to add Note to Notes collection of Order object.
Based on the documentation NewNote method may be used in order to create notes. Unfortunately, Order object does not expose such method.

Could you please advice?
BobRichards
Posts: 1377
Joined: Wed Jan 15, 2014 3:50 pm
Location: Raleigh, NC
Contact:

Re: How To create add Note to Order Notes collection

Post by BobRichards »

Get a new note object from the order, add text, then save the note to the order by adding it to the order's Notes collection. This same pattern is repeated from many objects.

Code: Select all

dynamic note = ((IOrder)_order).CreateNew("Note");
note.Text = {Your text string};
((IList)_order["Notes"]).Add(note);
Bob Richards, Senior Software Developer, SoftPro
oleksiy_tereshchenko
Posts: 8
Joined: Fri Oct 10, 2014 2:45 pm

Re: How To create add Note to Order Notes collection

Post by oleksiy_tereshchenko »

Bob, Thank you for your help.
Post Reply