Welcome to MSDN Blogs Sign in | Join | Help

Chris Johnson

All about Chris Johnson, SharePoint Products & Technologies & Other Stuff.
PDC 08 & SharePoint

I am really looking forward to PDC this year.  There is an awesome lineup of very cool stuff being announced.  The best thing about PDC is it is all about developers and seriously cool geeky new stuff … and to top it off I will be presenting a session on SharePoint development! 

SharePoint 2007: Creating SharePoint Applications with Visual Studio 2008

We will be using some very cool yet to be announced Silverlight features integrated with SharePoint.

I did an end to end dry run of the session today and it is shaping up really well.

This is no marketing session.  Most of the session is about building a real application live on stage for 45mins.  Showing you how you can build apps on SharePoint easily and all from within Visual Studio.

If you want to meet up at the PDC fire me a comment via this Blog.  Surely there must be some SharePoint folks going to the PDC?  I know AC is going! (Hey AC … we should do a SharePint)

PS: finding the PDC web site was an enjoyable experience with Live Search…

Live Search backgrounds are super cool too … today's is stunning.  Dont be afraid if you think this will slow down your searching … it doesn't … its loaded async after the  rest of the page.

LiveSearch

http://search.live.com/results.aspx?q=PDC+2008&go=&form=QBLH

If you are not in the USA you can switch to the USA using the locale picker in the top right:

image

Tesla at Microsoft

Tesla were on campus today showing off the Roadster.  Very very cool indeed.  The thing accelerated without a hint of noise and was really quick.  About $100k USD right now.

If you are an avid Xbox fan … yes that is Major Nelson standing by the boot trunk.  They were shooting some video so stay tuned for that.

Phone 002 Phone 001 Phone 003

In other automotive news on campus ….

I found a Prius in a bit of trouble on the side of the road.  The roadside assistance guy had the gas can out just prior to taking this … i thought that was kinda funny.

Phone 004

I’m a PC

http://www.microsoft.com/windows/

Phone 009

VSeWSS 1.2 in other languages…

We just went live with VSeWSS 1.2 in some more languages.  Here are the links to all the various languages we have now:

English

Chinese

Korean

Chinese – zh-tw

Japanese

We also have French, Spanish, German & Italian coming in the next couple of days. Stay tuned.

UPDATED:

French

Spanish

Italian

German

NZ on Live Search page…

Just saw this now … nice to see the homeland represented…

image

image

Live Search and the Olympics

I am not sure how many people feel the same way, but I am bored to tears of the simple white search page that most search engines have adopted.  There was a time and place for it … some would say it makes the page load faster, but to be honest most people use the search toolbar to do their searches anyway.

I normally have my default page set to Blank in IE.  But Live Search is doing something really cool with their home page during the Olympics (for US customers only at this stage).  They are putting images in the background that change twice a day.  I have changed my default page to live search out of interest to see what pops up.

I haven't noticed any speed decrease either which is nice.

image

image

UPDATED: Mens 4x100m Freestyle Relay USA win – Best swim race I think I have ever seen.

image

image

image

image

image

image

image

I switched from using Google a long time back.  Mainly because I work for MS and want to help make our product better.  At first it was painful, but now I find Live just as relevant.  The Live Search team are doing some really cool things that the other guys don’t do.  If you dismissed Live Search a while ago you should go and check it out again.

-Chris.

Bill’s last day

Today is BillG’s last day full time at Microsoft.  I just finished watching a live web cast of Bill’s last “town hall meeting”.  These are meetings where the execs of the company talk about the business and how we are doing etc… Today’s was obviously dedicated to Bill.

I have a sneaking suspicion that I don’t fully realize what a monumental day today is.  I suspect in 10, 20 or 30 years time I will look back and realize that today was the day that really defines Bill’s legacy. 

As big is the role that Bill has played in defining the computer industry (the biggest),  I feel that it will pale in comparison to the work he will now focus on full time.

He has always had world changing visions and dreams.  At the beginning of Microsoft it was to put a computer on every desk.  Now it is all about solving huge humanitarian issues like AIDS and world poverty.  Everyone has dreams to do great things … Bill actually does things to achieve them … no matter how big and world changing.

As much as many people despise Bill (many I think due to his success), he has changed the world once and there is no one else better equipped to change it a second time.  Bill 2.0

I know it sounds cheesy , but I joined Microsoft almost 6 years ago to be a part of something that changes the world.  Before Microsoft I had never felt the feeling you get from knowing literally millions of people are using software you directly had input in, it is something quite unique. 

Software is unique in that really you are only limited by what you can think up.  That is the magic of software… and Bill is taking that mantra of anything is possible to the next level.  I applaud his commitment and focus to these issues and really hope he changes world all over again … one more time.

Not many people get to change the whole world once, but to have the opportunity to do it twice? … Historic.

image

UPDATED: Building a simple ASP.Net page based SharePoint application in Visual Studio with the Visual Studio Extensions for WSS 1.2 with Visual Studio 2008

I have had a lot of feedback from people via email and comments that they really like the blog post I did about ASP.Net applications in SharePoint.

However,  there were a few “bugs” with that post, so I have decided to redo it with those fixed. 

This post builds the same example but with:

Here goes….

We will use Visual Studio 2008 & the Visual Studio 2008 Extensions, Version 1.2 to build a very simple 2 page ASP.Net page based application and deploy & run it in SharePoint.

For this you will need:

  • WSS or MOSS installed
  • Visual Studio 2008
  • VSeWSS 1.2

For help with installing WSS see: Install Windows SharePoint Services 3.0 on a stand-alone computer

Before getting started:

Make sure you can browse to your SharePoint site on http://localhost

E.g:
image

1. Create the project

Start Visual Studio

Create a new VSeWSS project (File->New->Project)

Under Visual C# in the left pane click “SharePoint

In the right pane choose the "Empty" project template.

Name it "DataEntryApp".

image

Click OK.  This will create a new VSeWSS blank project for us

Your Solution Explorer should now look like this:

image

Now we need to add some references to your project.

Right click on “References” and choose “Add Reference”.

Select & Add:

  • System
  • System.Data
  • System.Web
  • System.Xml

Your Solution Explorer should now look like this:

image

Now you have created the skeleton of the project we are ready to move on and start creating the pages & code that make up the solution.

2. Create ASP.Net pages

This is the part where we will create the ASPX pages.  To do this we will a Module to our solution.  Modules allow you to deploy files to various locations in a SharePoint site in which the your Feature is activated.  We are going to add two files to the Module.  The first will allow someone to enter some text and click a button to submit it.  The next will show that text that the user typed.

Right click the project and choose Add -> New Item. Make sure you have “SharePoint” selected in the left pane & select “Module” from the right pane

Call it "DataEntryApp.aspx"

image

Your Solution Explorer should now look like this:

image

Rename the sample.txt file to “DataEntryApp.aspx”.

Open the Module.xml file and change the following line:

image 
to
image

Add another Module called “DataDisplayApp.aspx

Rename the sample.txt file to “DataDisplayApp.aspx”.

Open the Module.xml file and change the following line:

image 
to
image

Your Solution Explorer should now look like this:

image

The next thing we need to do is add a couple of C# files that will have the code that sits behind our ASPX pages.  These will house the logic behind the submit button and the display form.

Right click your project and choose Add –> New Item.

Choose Visual C# in the left pane and Class in the right pane.

Name your file "DataEntryApp.cs".

image

Click Add.

Right click your project and choose Add –> New Item.

Choose Visual C# in the left pane and Class in the right pane.

Name your file "DataDisplayApp.cs".

image

Click Add.

Your Solution Explorer should now look like this:

image

We are now ready to start fleshing out the content of the pages and the code.

Open up "DataEntryApp.aspx" and add the following:

<%@ Page Language="C#"
    MasterPageFile="~masterurl/default.master"
    CodeBehind="DataEntryApp.cs"
    Inherits="DataEntryApp.DataEntryApp"
    Title="Data Entry Page"
     %>

<asp:Content ID="Content5" ContentPlaceHolderID="PlaceHolderMain" runat="server">

    <div>
        <asp:TextBox ID="EntryText" runat="server"></asp:TextBox>
        <asp:Button ID="SubmitButton" runat="server" Text="Button" />
    </div>
</asp:Content>

Open up "DataEntryApp.cs" and add the following code:

using System;
using System.Web;
using System.Web.UI.WebControls;

namespace DataEntryApp
{
    public partial class DataEntryApp : System.Web.UI.Page
    {

        protected TextBox EntryText;
        protected Button SubmitButton;

        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void Page_Init()
        {
            SubmitButton.Click += new EventHandler(SubmitButton_Click);
        }

        protected void SubmitButton_Click(object sender, EventArgs e)
        {
            Response.Redirect("DataDisplayApp.aspx?TextToShow=" + EntryText.Text);
        }
    }
}

Open up "DataDisplayApp.aspx" and add the following:

<%@ Page Language="C#"
    MasterPageFile="~masterurl/default.master"
    CodeBehind="DataDisplay.cs"
    Inherits="DataEntryApp.DataDisplayApp" 
    Title="Data Display Page" %>

<asp:Content ID="Content5" ContentPlaceHolderID="PlaceHolderMain" runat="server">

    <div>
        <asp:Label ID="TextToShow" runat="server" Text="Label"></asp:Label>
    </div>
</asp:Content>

Open up "DataDisplayApp.cs" and add the following code:

using System;
using System.Web;
using System.Web.UI.WebControls;

namespace DataEntryApp
{
    public partial class DataDisplayApp : System.Web.UI.Page
    {
        protected Label TextToShow;

        protected void Page_Load(object sender, EventArgs e)
        {
            TextToShow.Text = (string)Request["TextToShow"];
        }
    }
}

3. Build & Deploy

We are now ready to build and deploy the solution to SharePoint.  Couple of things before we do that however.

Open up the "WSP View" panel.  If you don’t see this you can find it under View -> Other Windows -> WSP View or CTRL+W, I

It should look like this when you expand the DataEntryApp top level item.

image

The WSP View shows you how your solution is going to be packaged into the WSP.  It allows you to drag and drop your Features around to get the model you want.  It also allows you to open the XML files and tweak with them if you want to.

Open the manifest.xml file.

Change the following:

image

to:

<Assemblies>
  <Assembly Location="DataEntryApp.dll" DeploymentTarget="WebApplication">
    <SafeControls>
      <SafeControl Assembly="DataEntryApp" Namespace="DataEntryApp" Safe="True" TypeName="*" />
    </SafeControls>
  </Assembly>
</Assemblies>

Now we are ready to build the solution

Build -> Build DataEntryApp

image

This will compile your projects code. 

We also need to package the solution into a WSP and deploy it to SharePoint.  Fortunately, VSeWSS does this for us so we don’t need to do any of this by hand like we had to in the past with scripts and nasty batch files.

Build –> Deploy DataEntryApp

image

If your deployment was successful you should see "Deploy succeeded" in the lower left of the Visual Studio window.

image

4. Try it out

Navigate to http://localhost/DataEntryApp.aspx

You should see a page like the one below. Enter some text in the textbox e.g. Hello World

image

Click "Button” & you should be taken to a page that displays the text you entered.

image

I hope this illustrates how simple it is to start creating a ASPX page based application in SharePoint.

If you have suggestions for future topics you would like me to post about on Development with SharePoint please comment.

Thanks,

-Chris.

VSeWSS v1.2 is available! - VS 2008 support!

Hi Everyone,

I just posted the announcement on the SharePoint team blog here: http://blogs.msdn.com/sharepoint/archive/2008/06/04/announcing-the-vsewss-version-1-2.aspx

This will address the number one ask from our developers ... Visual Studio 2008 support!

Happy SharePoint development.

-Chris.

Become a SharePoint Developer -www.MSSharePointDeveloper.com

SharePoint is taking off in ways we only could have imagined a few years ago.  Along with that comes a demand for developers to help implement and customize it for customers.  We are seeing a huge need for people with these skills in the market.

If you were ever thinking about becoming a SharePoint developer, now is a great time to do it.

To help you with that process MS has put together a great resource for helping you get started ... http://www.mssharepointdeveloper.com

It has a bunch of getting started material, hosted hands on labs you can take, whitepapers and more.

If you are new to development or a veteran ASP.Net developer and want to get started with SharePoint development this is the place to start.

image

Shuttle docking, New Zealand & XP

If there is one thing I love the Internet for its watching stuff happening in space.  I regularly tune in to Nasa TV when the shuttle is up to watch the goings on.

As I write this the shuttle is preparing to dock with ISS.  Its cool being able to watch this.

Along with realtime video footage you get shots of some animations of where the shuttle and ISS are at, like the one below.

Couple of things caught my eye a few mins ago ... 1) they were over home (New Zealand) & 2) the app showing all this in mission control is running on XP (nice to see it helping to run these missions).

image

WSSv3 on Vista

Yesterday Bamboo Solutions released a tool that allows you to install WSSv3 on Vista.  Developing on Windows Server has been a pain point for developers for quite some time & this workaround helps address that.

However,  I want to stress that this is not supported by Microsoft.  We have not tested WSS on Vista and thus make no commitment to supporting this.  However, I imagine that this will not bother many people and we will end up seeing this being a popular option.

We have known about this pain point for quite some time & I totally understand the pain everyone feels because of it.  I spent a lot of time in the field doing development on SharePoint and would have killed to not have to do that in a VPC / separate machine.  There are many reasons we hear about why people want to do this:

- They don't have a separate machine to install SharePoint on.
- Their organization does not allow Server installations on any workstations or VPCs.
- Their PC is not powerful enough to run a SharePoint virtual machine.

The list goes on ... but the 3 above are by far the most common.

To fully support another OM platform for our product is a big big deal.  It is a surprising amount of work to make sure everything works & we can certify that it does.  It is not simply a case of removing the OS block in our installer and letting the world have at it.  We must ensure that things work and that people wont loose data because of it.  Maybe some time in the future we will look at this, but for now we don't have any plans.

With the advent of Vista SP1 it was only a matter of time before someone did this.  Vista SP1 IIS is almost identical to IIS in Windows Server 2008.  IIS on Vista has some limitations such as a max request throughput count of 7 (or thereabouts).

Happy SharePoint development...

Thanks,

-Chris.

Update 6/9/08: I wanted to add a clarification to this post. You should always ensure that you are properly licensed for the software that you use. For Windows SharePoint Services 3.0 and other Microsoft software you should review the end user license agreement that is required before using that software.

Windows SharePoint Services 3.0 Tools: Visual Studio 2005 Extensions User Guide, Version 1.1

Big title for a big user guide! :)  This is a great step forward for people starting out with SharePoint development, or for people looking at starting with the VS extensions for SharePoint.

Anyone looking to build things like Webparts, Site templates, List temlates, Event handlers etc... should be looking at the extensions.  You can be up and running building a web part with Visual Studio in 5 mins and that will include all the WSP packaging too!

Right now the extensions are only for VS 2005, however by the end of June we should have the updated version for you that allows for VS 2008.  Stay tuned.

"This is the User Guide, Samples and Walkthroughs for the tools for developing custom SharePoint applications with the Visual Studio 2005 extensions for Windows SharePoint Services 3.0, version 1.1 (VSeWSS 1.1). The user guide has sections:

  • Starting out in SharePoint Development
  • Walkthrough of the VSeWSS User Interface including the WSP View
  • The Team Site Project
  • The Blank Site Project
  • The List Definition Project
  • The Web Part Project
  • The Workflow Projects
  • Project Item Templates
  • Best Practices with VSeWSS
  • Changes from 1.0 to 1.1"

http://www.microsoft.com/downloads/details.aspx?FamilyId=A8A4E775-074D-4451-BE39-459921F79787&displaylang=en

Download the extensions here:

http://www.microsoft.com/downloads/details.aspx?FamilyID=3e1dcccd-1cca-433a-bb4d-97b96bf7ab63&displaylang=en

Loving the new Zune update

Finally managed to get around to updating my Zune software to the new update.  Great to see TV shows in there like Battlestar Galactica and The Office.

image

I really like the Zune Card integration too.  Feeling more social already :)  It is cool to see what your fiends are listening to and be able to listen to them and/or download.  Very cool.  I always find it hard to find new music I like so it is nice to see what others are listening to.

Awesome to see that Auto playlists are back too! (i really missed them)

image

Loving the new Live Maps features...

I have used Live Maps for a long time now ... but they just keep adding awesome features!

http://virtualearth.spaces.live.com/blog/cns!2BBC66E99FDCDB98!14129.entry

Summary:

- Safari and IE8 compat
- Export your collections
- very cool new 3D improvements (see below)
- Labels in birds eye
- Party Maps
- Map cruncher integration
- Subscribe to a map and get notifications on people adding POI in those areas etc...?
- Hi-Def tour movies
- Traffic enhancements

image

More Posts Next page »
Page view tracker