Archive for November, 2006

RTW of WSS and Office SharePoint Server Standard and Enterprise Evaluation Can Now Be Downloaded

Thursday, November 16th, 2006

Looking for the final bits to WSS 3.0 and Office SharePoint Server 2007?

Check out Joel's blog for all the details!

Announcing the RTW of WSS and Office SharePoint Server 2007 Standard and Enterprise Evaluation!

I polled a couple of celebrities to see what their thoughts were when they heard the news.

First, I called John Madden on the Madden Bus.  When I told him the news he said, 'You know, about halfway through the preseason you start thinking to yourself that you're ready for the season to begin… and then BOOOOM!  The season is upon you!'


Next, even though I didn't have a problem, and no one else could help, I decided to give Hannibal Smith a ring.  All Smith had to say was, 'I love it when a plan comes together!'

 

HOW TO: Prevent creation of sub sites within MOSS 2007 My Sites

Tuesday, November 14th, 2006

What do you do to prevent your users from creating sub sites under their My Sites if you need to do so? Since there is not a way to shut down this ability from the Central Administration site you'll need to use some custom code to get the job done. The cool part is, I already wrote it for you. The solution I have created is very simple and leaves a very small footprint in your SharePoint environment, so it's easy to roll back to return your environment to a supportable state, or install future Service Packs.

The solution I've created consists of a Server Control and a custom aspx page. The Server Control is placed on the newsbweb.aspx page that is used to create SharePoint sites from a web browser.  The Server Control looks at the URL of the page being requested to determine if the request was made from a My Site.  If the Server Control finds that the request was initiated from a My Site it redirects the user to the custom ASPX page that lets them know they cannot create a sub site under a My Site.  The page has a link to return to the My Site, and it looks just like the other SharePoint pages because it uses the same application.master file.  If you change application.master the look and feel of the custom ASPX page will change along with all the other pages in the layouts directory.

You can download the VS.NET 2005 solution containing the code for the Server Control and the custom aspx page here.

To implement the solution follow these steps:

  1. Load the VS.NET 2005 solution named Custom.SharePoint.WebControls and build it.
  2. Copy the Custom.SharePoint.WebControls.dll file to the bin directory corresponding to the web site serving up your My Sites.
    1. For example, the My Site for the administrator on my development machine has a URL like this:
      http://moss-b2:30250/personal/administrator/default.aspx
    2. Therefore, the corresponding path on the file system to the bin directory for this web site looks like this:
      C:InetpubwwwrootwssVirtualDirectories30250in
  3. Next, edit the web.config file corresponding to the web site serving up your my Sites and add the SafeControl entry to register the assembly with SharePoint.
    1. You will find the SafeControl tag at the end of the AssemblyInfo.cs file in the Custom.SharePoint.WebControls project.
      1. It looks like this:
        <SafeControl Assembly="Custom.SharePoint.WebControls,Version=1.0.0.0,Culture=neutral" Namespace="Custom.SharePoint.WebControls" TypeName="*" Safe="True" />
      2. Copy and paste this value into the SafeControls section in the web.config file.
      3. Save the web.config file.
  4. Put the CanNotCreateMySiteSubSite.aspx file into the following directory on your SharePoint server:
    C:Program FilesCommon FilesMicrosoft Sharedweb server extensions12TEMPLATELAYOUTS
  5. Make a backup of your existing newsbweb.aspx file which you will find in the following directory on your SharePoint server:
    C:Program FilesCommon FilesMicrosoft Sharedweb server extensions12TEMPLATELAYOUTS
  6. Finally, copy the newsbweb.aspx file into the following directory on your SharePoint server:
    C:Program FilesCommon FilesMicrosoft Sharedweb server extensions12TEMPLATELAYOUTS

To test the solution, perform the following steps:

Open IE and navigate to your my Site.
Click Site Actions
Click Create
Click Sites and Workspaces
Notice the following page appears

That's all there is to it.

SharePoint Connections – Sessions Follow Up

Tuesday, November 14th, 2006

First of all I would like to say THANK YOU to everyone who came to my sessions last week! I had a wonderful time presenting my sessions to some great audiences and I really enjoyed meeting so many people after the sessions were over. I also enjoyed meeting many of the presenters and SharePoint MVPs at the conference. It was really nice to finally meet some of the folks who I have traded emails with for such a long time.

As I mentioned during the sessions, I'm following up on outstanding questions and comments in this post. I've broken down the information by session, so it is easier to locate.

HDV316: Integrating Applications with SharePoint – Without Writing a Line of Code!

Question: What Web Services are supported by the BDC?

Answer: The following information was taken from this article.

Business Data Catalog supports only "first" generation Web services. Therefore, if you are using Windows Communication Foundation Web Services, make sure you are using only WS-I Basic Profile v1.0. Business Data Catalog does not support the eight other binding choices that Windows Communication Foundation offers. For a sample, see the SampleWebService.

 

When you use Web services with overloaded methods, you cannot have multiple methods named identically in the Business Data Catalog metadata. A given entity can use only a single Web proxy method override at a given time. However, you can have multiple methods with the same name in the Web service. The Business Data Catalog will pick the correct method based on the signature in the metadata.

HDV419: Master Pages vs. Page Layouts (Types) in WSS V3

CODE: I've packaged several pages into a zip file you can find here.

This zip file contains the following:

  • Baseline.master – a minimal Master Page that you can use to build master pages to replace default.master.
  • CustomLayout.aspx – a customized Page Layout that began as the defaultLayout.aspx page which is the home page of the Publishing Portal template. The page has been customized to use a single Web Part Zone to display Web Parts.
  • CustomContentPages directory – contains two custom Content Pages and a Feature to install them.

STEP BY STEP INSTRUCTIONS TO USE THE FILES:

Making a new minimal Master Page and applying it to a site.

Navigate to a SharePoint Team site in IE.
Click Site Actions
Click Site Settings
Under the Galleries section, click Master Pages
Click Upload
Upload the Baseline.Master file

There are two ways to apply the page to the site:

  1. Here is a really cool Feature that installs a Web Part that allows you to pick the master page for a SharePoint site. Download this Feature, install it on your SharePoint Server, and then use it to set the Master Page.
  2. Open your site in SharePoint Designer, open the Master Page gallery node, select the Baseline.Master file, right click it and select Set as Default Master Page.

Installing and Activating the Custom Content Pages Feature.

Download the SharePoint Feature Manager Application from my blog
Copy the CustomContentPages directory in the zip file described above to the following folder on your SharePoint server: C:Program FilesCommon FilesMicrosoft Sharedweb server extensions12TEMPLATEFEATURES
Run the SharePoint Feature Manager Application
Type in a URL for a SharePoint site where you want to Install and Activate the new Content Pages (Ex: http://sever/sitedirectory/teamsite)
Click the Browse button
Open the CustomContentPages directory, and select the Feature.xml file
Click the Open button
In the Operation dropdown select Install
Click Compose
Click Execute
In the Operation dropdown select Activate
Click Compose
Click Execute
Copy the URL you typed in and paste it into IE, then add the names of the custom Content Pages named example.aspx and example2.aspx. (Ex: http://sever/sitedirectory/teamsite/example.aspx & http://sever/sitedirectory/teamsite/example2.aspx)

Installing an configuring a new custom Page Layout to replace the home page of the portal

Open IE and navigate to the home page of your Portal
Click Site Actions
Click Site Settings
Click Modify All Site Settings
Click Master pages and page layouts
Click Upload
Click Browse and locate the customLayout.aspx file in the zip file described above
Click OK to upload the file
On the subsequent web page enter Custom Page Layout in the Title text box
In the Content Type Group dropdown list select Page Layout Content Types
In the Content Type Name select Welcome Page
Click the Check In button
On the subsequent web page locate the customLayout.aspx, click the dropdown arrow next to it and select Publish a Major Version
Click OK

To change the home page of the portal to use the custom Page Layout perform the following steps:

Click Site Actions
Click Edit Page
Click the dropdown next to the Page link, and select Page Settings and Schedule
In the Page Layout dropdown list select (Welcome Page) Custom Page Layout
Click the OK button
Click the dropdown next to the Page link, and select Check In.
Click the OK button
Click the Publish button

To create a new page with the custom Page Layout perform the following steps:

Click Site Actions
Click Create Page
In the Title text box enter Custom Welcome Page
In the URL name textbox enter CustomWelcomePage
In the Page Layout list box select (Welcome Page) Custom Page Layout
Click the Create button
The subsequent web page will display the new custom Page Layout you created.
Click the dropdown next to the Page link, and select Check In.
Click the OK button
Click the Publish button

HDV218: Microsoft Office InfoPath 2007 Enhancements

One of the questions in this session was about submitting the same InfoPath Form from different Form Libraries to a common location. Andy researched the topic some more after the session and found this article which describes how to do it. Thanks Andy!

HDV317: SharePoint v3, Office 12, and Workflows, Oh My!

I mistakenly stated that the four out of the box workflows (Approval, Collect Feedback, Collect Signatures, and Disposition Approval) are available in Windows SharePoint Services 3.0 (WSS). They're not, they are only available in Microsoft Office SharePoint Server 2007 (MOSS) – however you can easily create them in WSS.

Thanks again for coming to my sessions everyone!