Showing newest posts with label SharePoint-Develpment. Show older posts
Showing newest posts with label SharePoint-Develpment. Show older posts

SharePoint WebPart Error - Unable to add selected web part (s) – MOSS 2007

SharePoint WebPart Error - Unable to add selected web part (s) – MOSS 2007SocialTwist Tell-a-Friend

ISSUE:

Recently I faced this issue that when I try to deploy my WebPart. 

Unable to add selected web part(s).

WebPartName: Cannon unregister UpdatePanel with ID ‘ctl00RTMPanel’ since it was not registerd with the ScripManager. This might occure if the UpdatePanel was removed from the control tree and later added again, which is not supported.
Parameter name: updatePanel.

 

image

I faced this issue twice and both the time the issue was not what display here. This could be sure to any error in the WebPart. Following are list resolution from multiple instances.

 

RESOLUTION:

1. Check the WebPartName.webpart file.

Check whether you have a proper PublicKeyToken value. When I face the issue the value was PublicKeyToken=$PublicKeyToken$.

If you have used WSP builder then in the Visual Studio you will find this file at \WebPartsProject\12\TEMPLATE\FEATURES\WebPartName\WebPartName.webpart.

Sometime when you create a new WebPart using WSP builder then you do not get the correct value. The WebPartName.webpart file looks like below. I have changed our PublicKeyToken to a sample key.

 

<?xml version="1.0" encoding="utf-8" ?>
<webParts>
<webPart xmlns="http://schemas.microsoft.com/WebPart/v3">
<metaData>
<type name="NamespaceName.WebPartName, WebPartName, Version=1.0.0.0, Culture=neutral, PublicKeyToken=99a999999d999999" />
<importErrorMessage>Cannot import WebPartName Web Part.</importErrorMessage>
</metaData>
<data>
<properties>
<property name="Title" type="string">WebPartName</property>
<property name="Description" type="string">web part for organizational chart.</property>
</properties>
</data>
</webPart>
</webParts>


2. Name of the WebPart should match the folder name. I mean if your WebPart name is WebPartName then the folder at \WebPartsProject\12\TEMPLATE\FEATURES\WebPartName should match to WebPartName.



3. Check you are getting proper data returned from your data provider and you are not missing any field in the return data. I was deploying my employee directory WebPart while UserProfile and People search scope was not configured properly. Once I fixed this issue everything worked great.



 



TROUBLE SHOOTING TIPS:


In both instance what I did was to create a brand new WebPart and copy code from old to new. Not complete code but few methods at a time. This greately help in pin pointing the issue.




Restoring Production MOSS 2007 Publishing Sites Into Development

Restoring Production MOSS 2007 Publishing Sites Into DevelopmentSocialTwist Tell-a-Friend

Restoring Production MOSS 2007 Publishing Sites Into Development - http://www.andrewconnell.com/blog/archive/2009/07/23/restoring-production-moss-2007-publishing-sites-into-development.aspx

Real World Branding with SharePoint Server 2007 Publishing Sites

Real World Branding with SharePoint Server 2007 Publishing SitesSocialTwist Tell-a-Friend

A very good article on SharePoint skinning….

Real World Branding with SharePoint Server 2007 Publishing Sites (Part 1 of 2) - http://msdn.microsoft.com/en-us/library/ee354191.aspx

Real World Branding with SharePoint Server 2007 Publishing Sites (Part 2 of 2) - http://msdn.microsoft.com/en-us/library/ee354190.aspx

SharePoint Development Tools

SharePoint Development ToolsSocialTwist Tell-a-Friend

I found this blog post “My SharePoint Development Tools” which list many useful SharePoint development tools. Few of them are must for each developer. Please check it out at - http://blogs.pointbridge.com/Blogs/morse_matt/Pages/SharePointDevelopmentTools.aspx

Real World Branding with SharePoint Server 2007 Publishing Sites

Real World Branding with SharePoint Server 2007 Publishing SitesSocialTwist Tell-a-Friend

A very good article on SharePoint skinning….

Real World Branding with SharePoint Server 2007 Publishing Sites (Part 1 of 2) - http://msdn.microsoft.com/en-us/library/ee354191.aspx

Real World Branding with SharePoint Server 2007 Publishing Sites (Part 2 of 2) - http://msdn.microsoft.com/en-us/library/ee354190.aspx

Windows Server 2008 And SharePoint 2007 VPC -– A Step By Step Install Guide

Windows Server 2008 And SharePoint 2007 VPC -– A Step By Step Install GuideSocialTwist Tell-a-Friend

Bellow is a step by step guide for creating Microsoft Virtual PC image for SharePoint 2007 development. The steps include configuration settings for creating Virtual PC machine & hard disk, installation & optimization of Windows 2008 and all development tools needed for development of SharePoint 2007. The step includes following tasks in order:

Bellow is more details on few important steps:

1. Prepare VPC – Create Virtual Hard disk & Virtual Machine & Install Windows Server 2008

I would recommend going through this article to install Windows Server 2008 using Virtual PC - http://blogs.technet.com/josebda/archive/2007/08/05/testing-windows-server-2008-using-virtual-pc-step-by-step.aspx - Testing Windows Server 2008 using Virtual PC (step-by-step)

This is a very good article on what options to select while creating virtual machine using the Microsoft Virtual PC. One change I strongly recommend is to use dynamic hard disk with hard disk size expandable up to 120GB. In dynamic hard disk you don’t need all 120GB space immediately and it will grow as needed. Max you can select is 130GB.

2. Run Windows Updates & select option for update from other products

Click at Get updates for more products. A new windows will open. Scroll down and accept the terms and click at install.

image

2. Convert your Windows Server 2008 to a Workstation -

http://www.win2008workstation.com/wordpress/

This website has great tips and I recommend these changes - Installation, Drivers, Wireless Networking, New User, Auto Logon, Shutdown Tracker, Ctrl+Alt+Del, Computer name, Performance, Internet Explorer Enhanced Security.

You may also want to follow these pages too but will cost some performance - Themes, SideBar with Custom Gadgets, Aero Cursors and Thumbnails, SuperFetch & Delay Activation.

3. Add Web Server IIS Role

Run Start->Programs->Administrative Tools->Server Manager. Then click on Add Role and 

image

image

4. Installing SQL Server 2005 on Windows Server 2008 -

The key is you must install the KB 950636 hotfix before installing SQL Server 2005.

http://www.codersbarn.com/post/2008/08/09/SQL-Server-2005-on-Windows-Server-2008.aspx

If you planning to install SQL Server 2005 Reporting Service also then you will need to install IIS6 compatibility features as well. Go through this article for exact details - Installing SQL Server 2005 Reporting Service on IIS 7  - http://igregor.net/post/2008/01/Installing-SQL-Server-2005-Reporting-Service-on-IIS-7.aspx 

image

You will also need to provisioning the admin user.

image