Change date of the news items

Posted by Community Admin on 03-Aug-2018 16:47

Change date of the news items

All Replies

Posted by Community Admin on 10-Nov-2010 00:00

Hello all,

I need change date of the news which was published at the site. How can I  make it? 

Posted by Community Admin on 11-Nov-2010 00:00

Hi Vitaly,

The NewsItem has a public property PublicationDate that you can use to switch the publication date of the item. There is a property DateCreated - gets or sets the date and time the content was created. By default the date created in DateTime.UtcNow;

If you work programmatically you can use the fluent API

App.WorkWith().ContentItems().Where(ci => ci.Id == contentItemId).ForEach(ci =>
   
// set content item property here.                                                                              
).SaveChanges();

You can see all properties exposed by ContentItem in our dev manual.

Best wishes,
Ivan Dimitrov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 15-Nov-2010 00:00

Thank you for your help!

This thread is closed