How to create a subsite thru code
From: arjun (arjun.chakraborty_at_gmail.com)
Date: 11/05/04
- Next message: Todd Baginski: "Re: Applying a template to a site?"
- Previous message: David McKenzie: "Re: Does Msft Tech monitor this group?"
- Next in thread: Daniel Larson (www.portalbuilder.org): "RE: How to create a subsite thru code"
- Reply: Daniel Larson (www.portalbuilder.org): "RE: How to create a subsite thru code"
- Messages sorted by: [ date ] [ thread ]
Date: 5 Nov 2004 06:14:07 -0800
Hi All,
I am trying to create a subsite in a sharepoint portal using the
following code
Site = New SPSite("http://localhost:8019/sites/test/")
Site.AllowUnsafeUpdates = True
Webs = Site.AllWebs()
web = Webs.Add("first12", "first", "first",
Convert.ToUInt32("1033"), SPWebTemplate.WebTemplate.TeamSite, False,
False)
But the code is giving me the following error
Updates are currently disallowed on GET requests. To allow updates on
a GET, set the 'AllowUnsafeUpdates' property on SPWeb
I have administrative privilages on the site.
Please help!
- Next message: Todd Baginski: "Re: Applying a template to a site?"
- Previous message: David McKenzie: "Re: Does Msft Tech monitor this group?"
- Next in thread: Daniel Larson (www.portalbuilder.org): "RE: How to create a subsite thru code"
- Reply: Daniel Larson (www.portalbuilder.org): "RE: How to create a subsite thru code"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|