Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problems deploying new web part 1

Status
Not open for further replies.

markknowsley

Programmer
Aug 30, 2005
152
GB
I'm trying to create a simple web part, and have followed the tutorial on (as well as a tutorial on devx) but can't get the Share Portal server to accept the web part as safe.

I'm trying to develop on a laptop and use one of three portals that we have on our server for deployment

Here's the process I've followed:
1. Downloaded the web part template from MSDN
2. Created a new project, added 'Hello World' to RenderWebPart
3. Created a strong key pair on c:\ on my laptop, set the assembly to point to this .snk file
4. Set the output path of the project to the bin directory of the portal site (on the server this is c:\inetpub\portalname\bin
5. Used sn.exe -T to get the keytoken for the project dll once solution is built, and added this (plus extra info) as a SafeControl to the web.config for the portal site
6. Updated the .dwp file on my laptop in Visual Studio with the assembly info, rebuilt the solution
7. Tried to import the web part onto the default.aspx page of the site, but get told it's not registered as safe

Can anyone see any errors in this process? Are there any better explanations about this development on the web?

Thanks in advance.

Mark.
 
I've had a lot of the same difficulties. I now use InstallAssemblies.exe from the Resource Kit or the wppackager anytime I want to deploy a webpart. I've had the same trouble following the same steps exactly as you have. Even with iisreset after step 7, I still get the "not safe" message.
 
Do you find that InstallAssemblies or wppackager work better? I tried packaging the web part into a .CAB file and installing it with the stsadm tool on the Share Portal Server but the web part was still 'unsafe'. The lack of any clear message as to where the problem is is frustrating.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top