Sharepoint 2010 : Visual Web Part in Sandbox : yes you can !










A few days ago, Mike Morton (MS) and the Visual Studio team released the Visual Studio 2010 Sharepoint Power Tools that allow us to create Visual Web Part running in sandBox mode but also to display build errors when we use unauthorized sandbox code ; you can download the tool here.

Create a Sharepoint 2010 sandbox empty project, add a Sharepoint project Item and the new template will show up:









Select Visual Web Part (sandBoxed) and a web part will be generate with an ascx control :










However, the ascx control won’t be deployed:














But everything relies on pure .Net code :



The other nice feature is that you won’t be able to type unauthorized code (class & methods) like SPSecurity, SPFram..:






Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s