Hi,
I have been asked to programmatically do the following in a SharePoint 2007 team site collection:
- Create a website using the OOTB blank site template. (Please note, for project specific reasons, we are not using customized site templates.)
- Activate the Publishing feature on the created website
- Activate a number of other custom features (for lists, etc)
- Create a page using a specified page layout (provisioned with webparts) and use this as the default page.
I have completed the first three steps successfully, but I am stuck on the fourth step. I can easily create a new publishing page via the SharePoint API, but how do I overwrite the default page with this new page? Or can I simply modify the web so that the new page becomes the default page for that website? Any advice would be appreciated.
Update
The code has to run on a button click, not in a Feature Event Reciever
Thanks, MagicAndi.