November Happy Hour will be moved to Thursday December 5th.
November Happy Hour will be moved to Thursday December 5th.
Solved it. For anyone else who hasn't found the documentation for it, here is the answer:
For this example, the main page is called NewCustomer.aspx. Input fields have been added to an asp UpdatePanel named ClientInfo (ClientInfo.ascx) that is part of the NewCustomer.aspx page. There are three types of input fields that have been added to this page -- a straight text input box, ID "BirthCity", a dropdown selection box with the ID "BirthCountry" and input box named 'DOB" which is using jQuery Datepicker calendar to select the date.
The following metafields were created in CommerceManager and added to the OrderForm (OrderFormEx): CityOfBirth - Short String, CountryOfBirth - Short String, IDDOB - Short String.
This code is added to the code behind (ClientInfo.ascx.cs).
===========================================
public OrderForm CaptureMetaFields
{
get
{
var orderForm = new OrderForm();
if (BirthCity.Value != null)
orderForm["CityOfBirth"] = BirthCity.Value;
if (BirthCountry.SelectedItem != null)
orderForm["CountryOfBirth"] = BirthCountry.SelectedItem.Text;
if (DOB.Text != null)
orderForm["IDDOB"] = DOB.Text;
return orderForm;
}
}
=====================================
NOTE: There is a "get". There is no "set".
This code was added to code behind for NewCustomer (NewCustomer.aspx.cs)
=====================================
// Insert OrderForm MetaFields
var orderFormId = ClientInfo.CaptureMetaInfo;
purchaseOrder.OrderForms[0]["CityOfBirth"] = orderFormId["CityOfBirth"];
purchaseOrder.OrderForms[0]["CountryOfBirth"] = orderFormId["CountryOfBirth"];
purchaseOrder.OrderForms[0]["IDDOB"] = orderFormId["IDDOB"];
purchaseOrder.AcceptChanges();
========================================
These two steps populated the fields in the database table OrderFormEx.
I am working with a messy installation of CMS6 R2. Normally, according to the documentation, it would be really easy to access the new metafields added to the Order Form. Not so for me. I have now been working all night at this. I have 12 new input fields on a page. They have equivalent metafields in the OrderFormEx metaclass. But I cannot figure out what the syntax would be to simply assign the values of the input boxes to the metafields.
I have dug through the site, and I am sure this is more than obvious, but not to me.
For example:
on the .aspx page:
* <%: translations.customerinformationiddateofbirth %>:
%:>
I need to map that to the "IDDOB" metafield on "OrderFormEx".
HELP!
Thank you!