Multiple User Controls in a SmartPart Project

May 20, 2008 at 8:28 PM
Can multiple user controls be added to a single SmartPart project? If so, do we need to simply create the appropriate .dwp files and modify feature.xml and manifest.xml to include the other controls? Also, could you provide an example of feature.xml and manifest.xml for a project that includes more than one user control?
Dec 23, 2008 at 10:51 AM
Anyone have ideia howto do this?
Nov 4, 2009 at 10:43 AM

Anybody an idea on how to do this?

I'm currently trying to achieve this but so far....no suc6 :-(

TIA!

Here are my (unsuccesfull) results. When I started I had 1 one usercontrol WebUserControl1. This one works fine.

Then I created a new one WebUserControl2 and tried to let it deploy automagicly The sections in BOLD and UNDERLINED are manually added steps.

I updated the Feature.XML:

<font size="2" color="#0000ff"><font size="2" color="#0000ff">

<

</font></font><font size="2" color="#0000ff">

 

</font>

ElementManifests>

<font size="2" color="#0000ff"><font size="2" color="#0000ff">

<

</font></font><font size="2" color="#0000ff">

 

</font>

ElementManifest Location="manifest.xml"/>

<font size="2" color="#0000ff"><font size="2" color="#0000ff">

<

</font></font><font size="2" color="#0000ff">

 

</font>

ElementFile Location="SmartPart.WebUserControl1.dwp" />

<font size="2" color="#0000ff"><font size="2" color="#0000ff">

<

</font></font><font size="2" color="#0000ff">

 

</font>

ElementFile Location="SmartPart.WebUserControl2.dwp" />

I updated the manifest.xml like so:

<Elements  xmlns="http://schemas.microsoft.com/sharepoint/">
  <Module Name="WebParts" List="113" Url="_catalogs/wp">
    <File Url="SmartPart.WebUserControl1.dwp" Type="GhostableInLibrary">
      <Property Name="Group" Value="SmartPart"/>
    </File>
      <File Url="SmartPart.WebUserControl1.dwp" Type="GhostableInLibrary">
          <Property Name="Group" Value="SmartPart"/>
      </File>

  </Module>
</Elements>

The new user control is added to the CONTROLTEMPLATES\SMARTPART folder (in the project and in the 12 hyves dir)

The new dwp is in the FEATURES\SMARTPART folder (in the project and in the 12 hyves dir)

 

ANy ideas on what I am missing?

<font size="2" color="#0000ff"><font size="2" color="#0000ff">

 

</font></font><font size="2" color="#0000ff">

 

</font>