More in this section

Forums / Developing with Sitefinity / Move page to different page group programmatically?

Move page to different page group programmatically?

3 posts, 1 answered
  1. Jenn Bohm
    Jenn Bohm avatar
    17 posts
    Registered:
    19 Aug 2009
    21 Mar 2010
    Link to this post
    I need to be able to programmatically move a page from one page group to another. The only way I thought of that I think would work would be to remove the page with CmsManager.DeletePage(guid), and recreate the page. This is a possibility, if we have to do it this way, but I wanted to check and see if there is a better way to do it.
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    22 Mar 2010
    Link to this post
    Hi Jenn Bohm,

    Before deleteing the page you need to copy it.

    1. Copy the page under the new node. You can copy a page using DuplicatePage method of CmsManager.
    2. Delete the old page.

    Sincerely yours,
    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.
    Answered
  3. Jenn Bohm
    Jenn Bohm avatar
    17 posts
    Registered:
    19 Aug 2009
    22 Mar 2010
    Link to this post
    As always, thank you so much for your help. This solution definitely sounds cleaner than what I thought I was going to have to do.

    thanks,
    jenn
Register for webinar
3 posts, 1 answered