Tuesday 23 November 2010

Mind your central admin ports in SharePoint

When you set up SharePoint 2010 you given the option of accepting the randomly assigned central admin port or selecting your own. Now because I like to know where my central administration site I usually pick my port number and to make like easy I take something easy to remember like port 10000. Normally this is not an issue as nothing is normally running on a port that high.

Recently I came across an issue whereby after a system reboot to update SharePoint with the latest ADO.NET Services software, the central administration site would not start and IIS would not bind to the port as it said it was already in use. It was a bit strange and I couldn’t figure out what had changed to the system other than my update.

Using the command line tool netstat I eventually found the culprit. BackupExec had been deployed to the domain and that uses port 10000 as a control port. Once this was figured out it was a simple case of changing the central administration port to another port and you can do this with PowerShell using the Set-SPCentralAdminstration –Port <PortNumber> (details)

So mind your ports!

Sunday 24 October 2010

Talks in November

6560.image_5F00_2DC376B7I am off down to Ireland in November thanks to Microsoft Ireland and I will be doing some talks for the Microsoft Technology User Groups around the country. All of the sessions are free, but registration is required so that we can track numbers and make sure we have seats for everyone.

Currently the Thursday slot is open if one user group wants to chime in an take it.

The current schedule is as follows

Monday 4 October 2010

Bing Maps Silverlight control weather mash-up with yr.no - Part 4

In this post, we will be adding the web service created in the previous post to the Silverlight application and using it to put pushpins on the map that represent weather data

So first off we will need to add the web reference to the application. Right click on the Silverlight project and click Add Web Reference. You can discover the one in the solution or else point it to where the web reference is located. I have named my reference InformationService.

Once its added, you should right click on the web reference and click update reference to ensure the proxy classes and addition code is created properly. Also if you attempt to build now and get an error about an assembly being missing (specifically relating to Serialization) right click on the web reference and click Configure Service Reference. Uncheck the Reuse types in referenced assemblies to fix this. This is a relatively rare error so just in case!

To use this in code you will need to add a using statement like so
1: using MashupMapApp.InformationService;
In the MainPage.xaml, we are going to create a new button that will use the web service to get the weather information and display it on the map. So the button is defined within the StackPanel like so
1: <Button Name="Search" Width="150" Background="Black" Click="SearchClick" Height="50" Foreground="White">
2:  <StackPanel Orientation="Horizontal" VerticalAlignment="Center" HorizontalAlignment="Left">
3:   <Image Source="images/2.png" Height="40" Width="40" VerticalAlignment="Center" HorizontalAlignment="Left" Opacity="1" MaxHeight="40" MaxWidth="40"></Image>
4:   <TextBlock Text="Været" VerticalAlignment="Center" HorizontalAlignment="Right" TextAlignment="Center" Width="109" Foreground="Black"  ></TextBlock>
5:  </StackPanel>
6: </Button>
Once you create the SearchClick method stub we will add some code to access the web service. So we need to create a SoapClient and then we need to add method handlers to the completed event and finally call the ASync method

So the method looks like the following
1:   private void SearchClick(object sender, RoutedEventArgs e)
2:         {
3:             var soapClient = new InfoServiceSoapClient();
4:             soapClient.GetAllWeatherCompleted += GetAllWeatherCompleted;
5:             soapClient.GetAllWeatherAsync();
6:         }
If you have ReSharper you can use it to create the GetAllWeatherCompleted method stub. Additionally I think there is that type of functionality in VS2010 at this stage too!

In the GetAllWeatherCompleted we will get the results of the asynchronous call to the web service which is the list of weather data. But first we need to set up the map again with a new layer like before.
1: var mapLayer = new MapLayer();
2: bingMap.Children.Add(mapLayer);
Next we will get the list of WeatherInfo objects which is contained in e.Result which in this case is an ObservableCollection
1: var weatherInfoList = e.Result;
The next thing is just to add each pushpin to the map and we can do this with a simple function wrapped in an even simpler foreach loop
1: foreach (var weatherInfo in weatherInfoList)
2:  {
3:   AddPushPin(mapLayer, weatherInfo);
4:  }
I will explain the AddPushPin method later in this post. First I will finish off the method GetAllWeatherCompleted. Finally I have some bit of tidy up code, which centres the map on the last item in the list and zooms the map in a bit. So the full method looks like this
1: void GetAllWeatherCompleted(object sender, GetAllWeatherCompletedEventArgs e)
2:         {
3:             var mapLayer = new MapLayer();
4:             bingMap.Children.Add(mapLayer);
5: 
6:             ObservableCollection<WeatherInfo> weatherInfoList = e.Result;
7: 
8:             foreach (var weatherInfo in weatherInfoList)
9:             {
10:                 AddPushPin(mapLayer, weatherInfo);
11:             }
12: 
13:             bingMap.CopyrightVisibility = Visibility.Collapsed;
14:             bingMap.LogoVisibility = Visibility.Collapsed;
15: 
16:             var itemLocation = weatherInfoList.LastOrDefault();
17:             bingMap.SetView(new Location(itemLocation.Latitude, itemLocation.Longitude), 9.0);
18:         }
In my App.xaml, I have a custom style which I will use to display the tooltip image. It uses databinding so that you just need to pass in the data context and the items will be databound to whatever they are specified to. This style sits in the application resources.
1:  <Style x:Key="WeatherInfoBox" TargetType="ToolTip">
2:   <Setter Property="Background" Value="Transparent" />
3:   <Setter Property="BorderBrush" Value="Transparent" />
4:   <Setter Property="BorderThickness" Value="0" />
5:   <Setter Property="Template">
6:    <Setter.Value>
7:     <ControlTemplate>
8:      <Border CornerRadius="5">
9:      <Border.Background>
10:       <SolidColorBrush Color="Black" Opacity="0.4"/>
11:      </Border.Background>
12:      <ContentPresenter Margin="5">
13:       <ContentPresenter.Content>
14:        <StackPanel Margin="5" MaxWidth="200">
15:         <TextBlock Text="{Binding Title}" FontWeight="Bold" FontSize="16" Foreground="White"/>
16:          <StackPanel Orientation="Horizontal">
17:           <Image Source="{Binding ToolTipImage}" Width="40" Height="40" />
18:           <TextBlock Text="{Binding TempC}" Foreground="White" FontWeight="Bold" FontSize="15" VerticalAlignment="Center" />
19:          </StackPanel>
20:          <StackPanel Orientation="Horizontal">
21:           <Image Width="40" Height="40" Source="{Binding WindImage}"/>
22:           <TextBlock Text="{Binding WindData}" Foreground="White" FontSize="12" VerticalAlignment="Center" TextWrapping="Wrap"/>
23:          </StackPanel>
24:          <TextBlock Text="{Binding Description}" Foreground="White" TextWrapping="Wrap"/>
25:         </StackPanel>
26:        </ContentPresenter.Content>
27:       </ContentPresenter>
28:      </Border>
29:     </ControlTemplate>
30:    </Setter.Value>
31:   </Setter>
32:  </Style>
As you can see certain values are databound to the names of properties within my WeatherInfo object. We will use the TooltipService object to apply the tooltip to the pushpin.

So now onto the AddPushPin method. This is the final method of the application. This as the name suggests actually puts you on the map. So like before we create a new image and set its location. The only additional idea here is the ToolTip that will be added to the pushpin.
1:  private static void AddPushPin(MapLayer mapLayer, WeatherInfo weatherInfo)
2:         {
3:             var pushPinImage = new Image
4:             {
5:                 Source =
6:                     new BitmapImage(
7:                     new Uri(weatherInfo.ImageLocation, UriKind.Relative)),
8:                 Width = 65,
9:                 Height = 65,
10:                 Opacity = 1
11:             };
12: 
13: 
14:             ToolTipService.SetToolTip(pushPinImage, new ToolTip
15:             {
16:                 DataContext = weatherInfo,
17:                 Style = Application.Current.Resources["WeatherInfoBox"] as Style
18:             });
19: 
20: 
21:             var location = new Location { Latitude = weatherInfo.Latitude, Longitude = weatherInfo.Longitude };
22: 
23: 
24:             MapLayer.SetPosition(pushPinImage, location);
25:             MapLayer.SetPositionOrigin(pushPinImage, PositionOrigin.Center);
26: 
27:             mapLayer.Children.Add(pushPinImage);
28:         }
04-10-2010 21-41-02Building your application will put this on screen and give you something like this (weather in Stavanger at the moment has people predicting how long its before we need to build an ark).

Finally the source code is being made available from here, sorry its taken a bit longer than expected.  Some notes, you will need to add your own key as described here and also you may need to re-add the Microsoft Map references if they are installed some place differently.

Microsoft MVP award ASP.NET

Microsoft_MVP_logoLate on Friday afternoon I got a fairly unexpected email with the title Congratulations 2010 Microsoft MVP.  I say unexpected because while I knew I was nominated I thought it was the December rotation and I hadn’t received the usual request for information from Microsoft. So now I am an MVP for ASP.NET!

It’s a real inspiration to get this award and to be honest considering some of the people I know who are current and former MVPs its also quite humbling.

Anyways, a quick bit about the Microsoft MVP award. The Microsoft MVP (Most Valuable Professional) program is a recognition program that is in place to recognize and reward those individuals who have been identified by individuals (peers, Microsoft staff, etc.) as experts in their technology field and global contributors to the technology. 

Sunday 19 September 2010

Bing Maps Silverlight control weather mash-up with yr.no - Part 3

In this post, I will take a look at creating a web service that will feed weather data to our Silverlight application that we have created in the previous posts
yr.noFirstly a little about where we are going to get the weather data from. yr.no is the joint online weather service from the Norwegian Meteorological Institute (met.no) and the Norwegian Broadcasting Corporation (NRK) and it offers weather forecasts in English (in addition to Norwegian Nynorsk and Norwegian Bokmål) for more than 700,000 places in Norway and 6.3 million places worldwide.

Yr.no supplies its weather data in XML format and you can get this XML by adding forecast.xml to the URL that is generated when you look for a location. For example for my current location in Stavanger, the generated address is http://www.yr.no/place/Norway/Rogaland/Stavanger/Stavanger/ and the XML for this http://www.yr.no/place/Norway/Rogaland/Stavanger/Stavanger/forecast.xml. This will generate most of the information in English.

To get this information in Norwegian you change the place to sted and use varsel.xml instead.

There are additional services provided by eKlima which you can use instead of yr.no if you wish. You can find more information on eKlima here.What I am going to do in this post, is creating the web service. So firstly we will create a web blank web application and a new web service to it.

In my project I have created a common library that contains a business layer, data layer and some classes. I have created a BaseInformation class which contains the basic information that is used by the map to create pushpins. This allows us to create more different objects which can use this class and make a generic method for adding pushpins with different data types, images etc.
1: public class BaseInformation
2:    {
3:        public int ID { get; set; }
4:        public string Title { get; set; }
5:        public double Latitude { get; set; }
6:        public double Longitude { get; set; }
7:        public string ImageLocation { get; set; }
8:        public string Description { get; set; }
9:        public string ToolTipImage { get; set; }
10:    }
The WeatherInfo class contains information specific to weather data and we will use this in our custom tooltip that we will be adding to the pushpin when its created on the map.
1:     public class WeatherInfo : BaseInformation
2:     {
3:         public string TempC { get; set; }
4:         public string FromTime { get; set; }
5:         public string ToTime { get; set; }
6:         public string SymbolName { get; set; }
7:         public string SymbolNumber { get; set; }
8:         public string WindData { get; set; }
9:         public string WindImage { get; set; }
10:     }
We have a simple class with an even simpler method that returns a generic list of strings that contains the XML addresses to download the information from yr.no.
1:    public IEnumerable<string> GetData()
2:         {
3:             return new List<string>
4:                        {
5:                            "http://www.yr.no/place/Norway/Rogaland/Sandnes/Sandnes/varsel.xml",
6:                            "http://www.yr.no/sted/Norge/Rogaland/Stavanger/Stavanger/varsel.xml",
7:                            "http://www.yr.no/place/Norway/Rogaland/Stavanger/Forus/varsel.xml",
8:                        };
9:         }
In the data layer we will create a new method that we will use to download the XML and manipulate it to our needs. The method stub looks like the following
1:       public static WeatherInfo GetWeatherInfo(string feed)
2:         {
3:            
4:         }
So first we need to download the XML file from yr.no. We use the XmlDocument class and use the Load method to load the XML.
1:             var xDoc = new XmlDocument();
2:             xDoc.Load(feed);
Since the XML file is quite large and contains multiple different elements we will create some datasets from the different elements and then use LINQ to join these datasets together and create the objects that we need.

So first creating the datasets from XML. This is a quick method which takes the name of the tag you want to turn into a dataset and the XMLDocument.
1:        private static DataSet GetDataSet(XmlDocument xDoc, string tagName)
2:         {
3:             var forecast = xDoc.GetElementsByTagName(tagName);
4: 
5:             var ds = new DataSet();
6:             var readerStream = new StringReader(forecast[0].OuterXml);
7:             ds.ReadXml(readerStream);
8:             return ds;
9:         }
We will create datasets from the following XML elements tabular, location, and forecast and we will join these together using LINQ. The following LINQ query is not the best in the world due its level of complexity so I apologise in advance if your eyes burn out of your skull and you decide to run off screaming “Oh the humanity”
1: from time in ds.Tables["time"].AsEnumerable()
2:                     join temp in ds.Tables["temperature"].AsEnumerable()
3:                         on time.Field<int>("time_id") equals
4:                         temp.Field<int>("time_id")
5:                     join symbol in ds.Tables["symbol"].AsEnumerable()
6:                         on time.Field<int>("time_id") equals symbol.Field<int>("time_id")
7:                     join windDirection in ds.Tables["windDirection"].AsEnumerable()
8:                         on time.Field<int>("time_id") equals windDirection.Field<int>("time_id")
9:                     join windSpeed in ds.Tables["windSpeed"].AsEnumerable()
10:                        on time.Field<int>("time_id") equals windSpeed.Field<int>("time_id")
That is the basic LINQ query and we will use that as the basis to generate a WeatherInfo object using the second part of the query.
1:  select new WeatherInfo
2:                     {
3:                         ID = time.Field<int>("time_id"),
4:                         TempC = temp.Field<string>("value") +"C",
5:                         FromTime = time.Field<string>("from"),
6:                         ToTime = time.Field<string>("to"),
7:                         SymbolNumber = symbol.Field<string>("number"),
8:                         SymbolName = symbol.Field<string>("name"),
9:                         WindData = string.Format("{0} {1} {2} m/s", windDirection.Field<string>("name"), windSpeed.Field<string>("name"), windSpeed.Field<string>("mps"))
10:                     }).FirstOrDefault();
The handy thing here is the cast of the WeatherInfo at the start to create an object that we can populate. Also the helper method FirstOrDefault(). If there is no records, it will create a blank object and we will return that. The Full method looks like this
1:     private static WeatherInfo GetWeatherInfoFromDataSet(DataSet ds)
2:         {
3:             return (from time in ds.Tables["time"].AsEnumerable()
4:                     join temp in ds.Tables["temperature"].AsEnumerable()
5:                         on time.Field<int>("time_id") equals
6:                         temp.Field<int>("time_id")
7:                     join symbol in ds.Tables["symbol"].AsEnumerable()
8:                         on time.Field<int>("time_id") equals symbol.Field<int>("time_id")
9:                     join windDirection in ds.Tables["windDirection"].AsEnumerable()
10:                         on time.Field<int>("time_id") equals windDirection.Field<int>("time_id")
11:                     join windSpeed in ds.Tables["windSpeed"].AsEnumerable()
12:                        on time.Field<int>("time_id") equals windSpeed.Field<int>("time_id")
13:                     select new WeatherInfo
14:                     {
15:                         ID = time.Field<int>("time_id"),
16:                         TempC = temp.Field<string>("value") +"C",
17:                         FromTime = time.Field<string>("from"),
18:                         ToTime = time.Field<string>("to"),
19:                         SymbolNumber = symbol.Field<string>("number"),
20:                         SymbolName = symbol.Field<string>("name"),
21:                         WindData = string.Format("{0} {1} {2} m/s", windDirection.Field<string>("name"), windSpeed.Field<string>("name"), windSpeed.Field<string>("mps"))
22:                     }).FirstOrDefault();
23:         }
In the GetWeatherInfo method we will finalise any properties in the object that we haven’t set before this. Such as the latitude and longitude. Now because in Norway the decimal separator is a comma (,) rather than the decimal point (.) this can cause some issues when doing conversions between strings and doubles. So we will use the NumberFormatInfo class to specify how the conversion should take place.
1: weatherInfo.Latitude = double.Parse(dr["latitude"].ToString(), NumberFormatInfo.InvariantInfo);
2: weatherInfo.Longitude = double.Parse(dr["longitude"].ToString(), NumberFormatInfo.InvariantInfo);
The full method for GetWeatherInfo is as follows
1: public static WeatherInfo GetWeatherInfo(string feed)
2:         {
3:             var xDoc = new XmlDocument();
4:             xDoc.Load(feed);
5: 
6:             var ds = GetDataSet(xDoc, "tabular");
7: 
8:             var weatherInfo = GetWeatherInfoFromDataSet(ds);
9: 
10:             var coDs = GetDataSet(xDoc, "location");
11:             var weatherDescDs = GetDataSet(xDoc, "forecast");
12: 
13:             weatherInfo.Description = weatherDescDs.Tables["time"].Rows[0]["body"].ToString();
14:             weatherInfo.Description = weatherInfo.Description.Replace(@"<strong>", "");
15:             weatherInfo.Description = weatherInfo.Description.Replace(@":</strong>", " -");
16: 
17:             weatherInfo.WindImage = "images/windsock.png";
18: 
19:             var dr = coDs.Tables["location"].Rows[1];
20: 
21:             weatherInfo.Latitude = double.Parse(dr["latitude"].ToString(), NumberFormatInfo.InvariantInfo);
22:             weatherInfo.Longitude = double.Parse(dr["longitude"].ToString(), NumberFormatInfo.InvariantInfo);
23: 
24:             weatherInfo.Title = coDs.Tables["location"].Rows[0]["name"].ToString();
25:             weatherInfo.ToolTipImage = "images/temp.png";
26:             weatherInfo.ImageLocation = string.Format("images/{0}.png", weatherInfo.SymbolNumber);
27: 
28:             return weatherInfo;
29:         }
In the Business layer we have a simple method that creates a list of these weatherInfo objects based on the list of feeds that I talked about earlier.
1:  public static List<WeatherInfo> GetAllWeatherInfo()
2:         {
3:             var allFeeds = new FakeWeatherFeeds().GetData();
4: 
5:             var weatherInfos = allFeeds.Select(WeatherInfoDl.GetWeatherInfo).ToList();
6: 
7:             return weatherInfos;
8:         }
Instead of a foreach loop I am using some LINQ to pass in the method and create the list. And finally the web service method looks like the following.
1: [WebMethod]
2:         public List<WeatherInfo> GetAllWeather()
3:         {
4:             return WeatherInfoBl.GetAllWeatherInfo();
5:         }
In the next post we will put this altogether with the Silverlight map application and binding the list of objects to the map.

Friday 17 September 2010

Bing Maps Silverlight control weather mash-up with yr.no - Part 2

Following on from the previous post will now look at adding pushpins to the map.

PushPins inherit from the UIElement class meaning that any UIElement can be used as a pushpin. So that means we can use Images as pushpins. So first lets add a normal pushpin to the map.

We are going to add a button to our map and wire up an event handler to add a pushpin to the map. In MainPage.xaml in your grid add a button

In the Button_Click event we are going to create a new MapLayer and add the pushpin to it. The pushpin is going to mark the location of the Empire State Building in downtown New York. It uses the following decimal co-ordinates. In MainPage.xaml.cs



using Microsoft.Maps.MapControl;

private void Button_Click(object sender, RoutedEventArgs e)
{
MapLayer mapLayer = new MapLayer();
bingMap.Children.Add(mapLayer);

Location location = new Location { Latitude = 40.748687, Longitude = -73.985549 };

Pushpin pushpin = new Pushpin {Location = location};

mapLayer.Children.Add(pushpin);

}


What we have done here is created a new MapLayer object and added that to the children collection of the parent Map. We then create a location object with the co-ordinates of the Empire State Building and create a new pushpin at this location. We finally add the pushpin to the map layer which shows it on the map.



This is a bit simple and being honest a bit boring. So lets mix it up a bit.


450px-Empire_State_Building_from_the_Top_of_the_RockSince we are using the Empire State Building, I am going to use an image of this renowned landmark and use that as its pushpin. So a quick look on wikipedia for an image we find the one on the left (http://en.wikipedia.org/wiki/File:Empire_State_Building_from_the_Top_of_the_Rock.jpg). We will use this image and load it as the pushpin in our map.

Just like before we are going to add a new button to our map. But we are going to encapsulate both buttons in a StackPanel so that we can arrange them easily.



I have downloaded the image and created a new folder in my Silverlight application called images and placed the image in there. I renamed it to Empire.jpg just so I wouldn’t have as much to type. If you want to use the image directly from Wikipedia you will need the following URL http://upload.wikimedia.org/wikipedia/commons/c/c7/Empire_State_Building_from_the_Top_of_the_Rock.jpg and use the UriKind.Absolute option.


In MainPage.xaml you will need to replace your button code with the following.


In MainPage.xaml.cs


So in this code sample, we are doing something very similar to the previous sample. First you create a new layer and as before add it to the parent map. Next you create a new image with a source from either a relative or absolute Url and set its height and width. The difference now is that we use the MapLayer methods to set the position for the Image we created and finally add the image to the maplayer object.

In the next post, I will go through getting weather data from yr.no and using LINQ to create weather data objects that can be rendered on the map using the above methods.

Tuesday 14 September 2010

Bing Maps Silverlight control weather mash-up with yr.no - Part 1

So I have shown before in a previous post how to use the AJAX version of the Bing Maps control. Now I am going to show the new version of the map control that is in Silverlight. Microsoft have released the Bing Maps Silverlight Control SDK which you use to add map control to your website.

Now in comparison to the AJAX version, this new version is smooth. In fact its much easier to program with and you can do a lot of nice things with it. One of the biggest advantages is the fact that pushpins on the map can be anything that inherits from the UIElement class. This means you can have controls, user controls or images as pushpins. This functionality in itself extends the possibilities of customising the UI experience for your users. Additionally there is added benefit of the rich UI features of Silverlight that can allow to extend aspects of the map to your liking.

So how do you start all this great stuff.

  1. Go to the download site and download and install the SDK
  2. Surf to the Bing Maps Account portal and create a new account
  3. Generate a new developer key
  4. Open Visual Studio and get started!
    1. Note that for all this I am using Visual Studio 2010 and Silverlight 4. You can download the Silverlight 4 Tools for VS 2010 from here

So lets do that

1

First we are going to create a new Silverlight Application. If you get prompted download the Silverlight Developer runtime and install it.

Next choose the option to host the Silverlight application in an ASP.NET Web application. This just adds the boilerplate code for you to show your application in a web page.

Now you should have a nice simple application with your basic Silverlight application loaded and standard ASP.NET web application created.

You will need to add the Bing Map DLLs as references in your project. Right click on the references folder and browse to where you installed the SDK. If you chose the default installation path you will find it in your Program Files directory or (x86) directory on 64bit Windows in Bing Maps Silverlight Control. You will find the DLLs you need in the V1\Libraries directory. You will need both of them which are

  • Microsoft.Maps.MapControl.Common
  • Microsoft.Maps.MapControl

Once they are added we can use the Bing Maps Silverlight Control in our Silverlight application.

Add the namespace to your XAML code

xmlns:Maps="clr-namespace:Microsoft.Maps.MapControl;assembly=Microsoft.Maps.MapControl"

You can reference the maps by using the Maps prefix. Inside in the grid add a map control

<Grid x:Name="LayoutRoot" Background="White">
   <
Maps:Map Name="bingMap" CredentialsProvider="Your key here"></Maps:Map>
</
Grid>
 
You need to create a new key in the Bing Maps Account portal if you haven’t already done so and then copy it into the CredentialsProvider so that your map will work correctly otherwise you will see an invalid credentials warning on your map.
Your code should look like this
<UserControl x:Class="MashupMapApp.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:Maps="clr-namespace:Microsoft.Maps.MapControl;assembly=Microsoft.Maps.MapControl"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="400">

<
Grid x:Name="LayoutRoot" Background="White">
<
Maps:Map Name="bingMap" CredentialsProvider="your key"></Maps:Map>
</
Grid>
</
UserControl>

Pressing F5 to debug should bring up the Silverlight map control in its test page.


In the next post, I will go through adding standard and custom pushpins to the map.

Friday 25 June 2010

NDC 2010 Review

NDC2010.jog Like last year, I was fortunate enough to attend the Norwegian Developers Conference or NDC 2010. It was held again in Oslo but this time in Oslo Spektrum in the centre of town . There was 7 different tracks which covered a lot of different development technologies including web development, test driven development, AGILE and SCRUM project methodologies and architectural patterns and practices.

 

The conference organizers managed to raise the bar once again in terms of speakers and content. The speaker line-up contained a whole cross section from the development community. Speakers like Rob Conery, Bob C Martin, Itzik Ben Gan, Michael Feathers and some of the brightest stars in the Norwegian community such as Jonas Follesø, Frederik Kalseth and Mark Nijhof.

I got to Itzik Ben-Gan’s talks on Advanced T-SQL Tips & Tricks and also Pivoting SQL data. Itzik managed to show some exceptional ways to simplify queries and also to think a slight bit differently on how you would perform some common queries.

The overflow solution this year was nick named the “ADD Room” or “Mission Control” by some. It consisted of 7 large screens suspended over section of the arena. You picked up a set of wireless headphones and you could watch the session from the seats below. It worked really well and even better when you discovered the VIP box seats which has some extra leg room and more comfortable seats. A lot of people managed to figure this out by the end.

DSC06584 The Thursday nights entertainment was provided by the Ralph Myerz & Jack Herron Band who rocked the place. Some great percussion and funky rhythms. Hugely enjoyable.

A couple of us also headed over the nearest Irish pub, and by tradition you must bring an Irishman as a form of identification. I got to chat again to Scott Bellware (who has an excellent post on NDC), Tibi Covaci, Rob and many others. It was great to get some interesting takes on speaker styles, presentation techniques and other such stuff.

I quite enjoyed Rob Conery’s talk on WebForms vs MVC on Friday morning which was an interesting talk and there has been much, in some parts very heated debate on twitter and on his blog post about it.

For me, it was more whatever you use there is no need to be militant (one of my personal stances), but to also leave your mind open to other options. Additionally some innovation has stagnated coming out of the main tool provider(s). Maybe I am looking too simply at this and not reading as much into it as much as everyone else but at least that it was I took from it.

Jon Skeet did a great session on what he thought should be in C# 5.0 (which Ben Hall commented “isn’t that just Ruby”) which was followed by a panel discussion by Mads Torgersen, Jon Skeet, Eric Lippert and Neal Gafter on where C# 5.0 is going.

.NET Rocks presenters Carl Franklin and Richard Campbell presented the 64 Bit question where people won some nice prizes. Also Carl did an impromptu session along with myself, Ingo Rammer, Tibi Covaci and Rune Grothaug (who took the video)

The folks at ProgramUtvikling, Rune Grothaug and Anders Norås should be commended with the excellence that was the Norwegian Developer Conference 2010.

Which leaves me with this. The Norwegian Developer Conference should be a prescribed part of your developer education. The conference is progressively raising the bar on how developer conferences should be run. The level of the talks, the quality of the speakers added to the amount of post discussion means that if you miss it, you miss out on a very valuable resource.