Posts tonen met het label Visual Studio 2008. Alle posts tonen
Posts tonen met het label Visual Studio 2008. Alle posts tonen

vrijdag 1 april 2011

How to deploy a custom web part in SharePoint 2007

Build you created web part in VS2008. Using Windows Explorer you go to you Debug  or Release map from your project:

… \Documents\Visual Studio 2008\Projects\TestSPWebPart\TestSPWebPart\bin\Debug\

Afterwards you copy the .dll file to the bin map from you SharePoint server (C:\inetpub\wwwroot\wss\VirtualDirectories\80\bin\)

Now you have to open the web.config file (location: C:\inetpub\wwwroot\wss\VirtualDirectories\80\), in that file you have to enter a SafeControl in the correct format,

<SafeControl Assembly="<Assembly name>" Namespace="<namespace of the assembly>" TypeName="*" Safe="True" AllowRemoteDesigner="True"/>

For instance:
<SafeControl Assembly="TestSPWebPart" Namespace="TestSPWebPart" TypeName="*" Safe="True" AllowRemoteDesigner="True"/>

When you have don that you open the root page of your SharePoint site, this is also accessible using localhost. When Internet Explorer opens the page you go to the Site-Actions in the upper right of the corner and open all the Site Settings – afterwards you choose for Web Part under Galleries.

image

There you choose “New”, normally on the bottom of that list you will find your web part, then after you have selected the web part you go back to the top and click “Populate Gallery”.

 

imageimage

After you have populated your gallery of web parts, you can use the web part in a all pages, even in other sites.

zondag 27 maart 2011

Developing for Microsoft Office SharePoint Server 2007 (64-bit)

After I’ve installed  the SharePoint server 2007 64-bit and Visual Studio 2008. I’ve tried to create a Web part. But no options were available in VS2008 for SharePoint server 2007 64-bit. Afterwards I’ve, alongside VS2008, I’ve installed VS2010. But there it was possible to create something for SharePoint Server 2007 32-bit, not for the 64-bit version.

When you tried to create a Web part for instance you get following error:

fout visual studio

After checking out the internet for this problem, I found on msdn from Microsoft and on the msdn blog. That it was impossible to create a part for SharePoint Server 2007 64-bit. My boss then found a installer on the Kamp’s Blog. But after installing it didn’t work.

Our final solution was to reinstall Windows Server 2008 and SharePoint Server 2007 but everything in 32-bit modus.