How to set publish at and unpublish at date in contentservice?

Hi there,

I have been wondering how I can set the publish at and unpublish dates from within the method of a webservice:

All my custom fields are set by using code like the following:

var newproduct = contentService.CreateContentWithIdentity(Headline, parentId, "product");

            product.SetValue("sortDate", SortDate);

But how can I address the fields for publish and unpublish?

Any ideas?


This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/90678-how-to-set-publish-at-and-unpublish-at-date-in-contentservice