Deleting a document
[C#]
// Tree provider CMS.TreeEngine.TreeProvider provider = new CMS.TreeEngine.TreeProvider(CMS.CMSHelper.CMSContext.CurrentUser);
// Get document with specified site, aliaspath and culture CMS.TreeEngine.TreeNode node = provider.SelectSingleNode(CMS.CMSHelper.CMSContext.CurrentSiteName, "/News/MyFirstNews", "en-us");
if (node != null) { // Delete the document node.Delete(); } |
Page url: http://devnet.kentico.com/docs/devguide/index.html?delete_document.htm