I am trying to use the API to hide a SKU from showing on the site by using the "Publish TO" value and setting the date to now. If I go to the CMS Desk, browse to the product in the content tree and set the flag, it works fine, but I can't seem to figure out how to set it via the API. Is this not possible? I have this sudo code:
For Each productDoc As SKUTreeNode In tnds.Items
'productDoc.DocumentPublishTo = Now() 'THIS IS READONLY
productDoc.SetValue("PublishTo", Now()) 'so I tried this
productDoc.Update()
Next
The DocumentPublishTo property is read only so that won't work. The SetValue did not throw an error but that did not actually update the field. I can't find anything else in the API documentation to try... Any ideas what I am missing?
Thanks,
Matt