Page 1 of 1

Property used in InputField input to assign a value

Posted: Tue Aug 24, 2010 3:29 pm
by Dylan
Hi,

What property is used in the InputField input to assign a value

// ADD IN THE PRODUCT TEMPLATE CHOICES
foreach (ProductProductTemplate ppt in product.ProductProductTemplates)
{
ProductTemplate template = ppt.ProductTemplate;
if (template != null)
{
foreach (InputField input in template.InputFields)
{
// What property is used here to set a value entered
input.

Thanks

Dylan

Re: Property used in InputField input to assign a value

Posted: Tue Aug 24, 2010 9:56 pm
by s_ismail
It can be like this

Code: Select all

  foreach (ProductProductTemplate ppt in product.ProductProductTemplates)
        {
            ProductTemplate template = ppt.ProductTemplate;
            if (template != null)
            {
                foreach (InputField input in template.InputFields)
                {
                    // What property is used here to set a value entered
                    input.Name = "test";
                    input.Save();
                }
            }
        }