Developer forum

Forum » Development » Creating news-item

Creating news-item


Reply
 Hey everyone.

Is there a method for creating a news-item in the NewsV2 module?
I'm looking for something like this:

Dynamicweb.NewsV2.Item.CreateNewsItem(...)

Replies

 
Reply
Hey Bo,

Try something like this..

var item = new Dynamicweb.NewsV2.NewsItem();
item.NewsCategoryID = 123;
item.NewsHeading = "Breaking News: html24.dk conquers the world";
item.NewsText = "blah blah blah";
item.Save();

/Morten

 

You must be logged in to post in the forum