Blog Home  Home Feed your aggregator (RSS 2.0)  
.Net Jonesie - Monday, September 03, 2007
A simple programmers blog
 
# Monday, September 03, 2007

UpdateI Love SharePoint

 

A lot of people seem to think that Sharepoint and MOSS are wonderful things - a joy to behold!  As of today, I am not one of them.

I've been handed two jobs that require the use of InfoPath forms.  The first is to create a Leave Application form for our intranet.  The other is a bigger project of about 30 forms for a local government site.

As these seemed relatively straightforward things to do I thought it would be a good opportunity to learn and dispel my bad impressions.

So, this is a dynamic post of the issues I have with InfoPath, WSS, MOSS & Forms Services.  As I find solutions or overcome my frustrations I will update (and apologise where necessary).  I'll also include a summary at the end and my current mood.

InfoPath Issues

Contact Selector

This is an ActiveX control that is used on InfoPath forms to allow users to select a user from ActiveDirectory.  It requires inclusion of a custom data source (xml file) and creation of fields with very specific names. 

  1. To use more than 1 contact selector on the page requires you to create reference fields - which currently confuse the hell out of me.
  2. Because you can only have a single Context data source in the form, all contact selectors will work against the same domain.
  3. There is no way to filter what the user can select.  I want a contact selector to only allow groups to be selected.  This is not possible.
  4. Contact selector does work on browser enabled forms.  It is the only ActiveX control that does this and it appears as though it's hard wired to work.  According to the InfoPath blog there is absolutely no way to create your own ActiveX control that will work in browser forms.
  5. Setting a rule on drop down lists will get you 6 level deep in modal dialogs.  This is a very bad UX.

Lookups

I can attach a drop down list to Sharepoint list very easily but I can only set the display and value fields.  The list I'm displaying has 3 values - ID, Team Name and Manager Email.  I store the ID in the form, display the Team Name in the drop down and I need to find the Managers Email from the Workflow when the form is submitted.

Designer

  1. Moving tables is impossible.  You can't drag and drop a table and cutting and pasting will trash the contents.

Sharepoint Designer Issues

Getting pretty picky now.

  1. When editing a workflow, you can't right-click the Workflow item and select New workflow.  You have to go to the file/new menu option for that.
  2. Cannot change the format of emails sent from the workflow.  The emails are pretty ugly really.
  3. Workflow Lookups are very confusing. 

WSS Issues

  1. All to often you fall off the edge of the Sharepoint world and are required to use command line tools - the horrendous STSAdm.exe mostly.  This has more options than a Linux command shell!  I understand the need for a command line tool but why-oh-why isn't here a GUI version?
  2. Publishing an InfoPath form to Sharepoint is pretty easy until you want them browser enabled.  This requires an admin install of the template.  An admin install requires 1) access to the central admin site, 2) an upload of the file from a hard drive (not from a Sharepoint list), 3) activation of the template in a site and 4) configuration of a list to use the new content type created for the form, 5) local machine administrator group membership. This is bloody ridiculous when you consider that publishing a non-browser enabled form works from InfoPath with 3 or 4 clicks of the mouse.
  3. The help is complete rubbish.  It's either far to simple or vague or blank.

Workflow Performance

You cannot have more than 10 workflow's active on a single list and submitting 3 forms with workflow concurrently to the same list kills the server. This was proven for another site we did recently.  If I was paying the (huge) bill for MOSS, this would be a show stopper.  Thankfully there is K2.

Update: I've been informed by someone much more informed than I (thanks Paul) that there is no 10 workflow limit.  In fact there is a WSS property that can be set to specify the event delivery throttle.  I wish we had know about this a lot sooner - it's too late for 1 customer :(.  Full details here:  http://technet2.microsoft.com/Office/en-us/library/93a3282e-00d2-4d03-9721-df42b5aa7cfb1033.mspx?mfr=true

Deployment

I have yet to do this but from what I have seen - don't go there.  Create your forms and content directly into your production environment. 

  1. You can't package forms in a STP file.  You have to deploy these separately.  This will probably require hacking the raw XML files of the form.  You also need to generate a .JS script file or MSI using yet another command line tool.

Summary

There are sooo many holes in WSS & MOSS  & related tools that it's a wonder anyone is using it.  When you consider that this is the 3rd version of Sharepoint - albeit a massive re-write - it's woefully inadequate.  It's much more like a v1.0 product.

If you need to create InfoPath forms that require any custom code - DONT!  Just create a windows or web app that talks to Sharepoint lists.

If you have complex workflow requirements or require high performance - use K2 or host workflow's in your own service - DONT use Sharepoint for it.

Current Mood: Tony says I'm Indifferent but I feel reluctant. Not nearly as grumpy about SharePoint as when I wrote this but reticent to withdraw the post completelty.

Monday, September 03, 2007 1:32:11 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [2]   General | Sharepoint  | 
# Sunday, August 26, 2007

Word has leaked out already (not that is was a big secret) so I had better blog about it myself.  We are organising a .Net Code Camp for November in Christchurch.  Currently details are a little sketchy, but I can tell you this:

Name: Code Camp Boot Camp

Theme:  Next generation, back to basics.  New releases of C#, VB, .Net, ASP and SQL are iminent.  This code camp will focus on getting up to speed with all of this, plus cover migration stratigies and many non-technology specific topics such as Architecture and Development Life Cycle.  Hopefully something for everyone - noobs, gurus, young and old.

Date: We don't yet have a fixed date, this is highly venue dependend - see Venue - but it will be a weekend (Sat/Sun) in or around Christchurch.  This excludes Show Weekend (17/18th) which is a very busy time here.

Venue: We don't yet have a venue, but are looking at a couple of strong possibilities.  There are many likely venues but finding one that is comfortable for a whole weekend and free is tricky. 

Speakers: Presenters will be mostly mainlanders with a few imports from north of the Kaikouras.  If you would like to present then please contact me ASAP.

Sessions: We have a list of possible topics that we want to see covered, but this is very dependent on the speaker and their area of expertise.  More details once we know who the speakers will be.

We have a great team of volunteers (some of whom don't yet know they have 'volunteered' :) and lots of great ideas so I'm sure this will be a very memorable event.

We are unsure of the level of attendence we can get so if you are at all interested in attending it would really help us if you pre-registered. For this and other details see http://codecamp.net.nz.

Sunday, August 26, 2007 10:45:33 AM (New Zealand Standard Time, UTC+12:00)  #    Comments [2]   General | NZ .Net User Group  | 

I'm late to the debate (here, here and here amongst others) and I don't have anything very intelligent to offer, but that has never stopped me before.

It occurred to me that since Microsoft has already released a major product (Office 2007) reliant on Open XML that it doesn't matter which way the vote goes.  Open XML IS a standard.  Get over it already.  Endless arguments and debates over it's technical or political merits are pointless.  Microsoft won't be adopting some other standard any time soon - they stuck with the previous closed standard (.doc etc) for many years and only changed it when they had to / wanted to.  At the very least they are now trying to do what everone has been nagging them to do for so long.  We should be grateful!

Sunday, August 26, 2007 10:16:56 AM (New Zealand Standard Time, UTC+12:00)  #    Comments [0]   General  | 
# Sunday, August 19, 2007

I was waving a quick meeting in a local restaurant last week about some user group activities when we were interupted by someone from the next table.  He asked if we worked for Microsoft.  We laughed and I said something like yes, but we dont get paid for it.  Well it turns out the crowd at the next table worked for a local Open Source development shop and the person who approached us was one of the most 'open source' of them.  When I realised this I made a lame joke about how we get paid for our software. 

Yes, it was a very lame joke but it turned out he didn't think so.  In fact I think he may have taken it a little to personally. So, if your reading this, I'm sorry.  I was just attempting a mild wind-up.

However, I really dont get it.  Why are so many open source advicates so incredibly sensitive?  I have never agreed with the open source fundemantal mantra that many part-time developers is better than a few well paid brialliant ones.  Yes, maybe software can cure cancer, foster global peace and be the eternal source of future happiness, but that doesn't mean we all need to have the right to change the code for this to happen. 

And will someone please explain to me why they think Microsoft is so anti open source?  What a complete crock!  Nearly every day I use source code provided free and openly by Microsoft. Ok, so I can't recompile Windows, but do I give a frac?  No.  In fact I'm sure it would be a much worserer world if every nerd and his pc could modify and recompile KERNEL.EXE.  I have no argument with Microsoft making money from software. Sometimes I think they ask too much for their software - especially in this part of the world - but I hardly ever have to pay for it so I dont care that much.

From my very limited field of vision it's all about productivity.  If someone can show me a platform that is as productive, powerful, flexible and open as Microsoft's, where it's possible to make lots of money, then I will be happy to consider retraining.  Until then, will all you open source preachers please take a pill and calm down!

Sunday, August 19, 2007 9:52:20 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [2]   General  | 
# Sunday, July 22, 2007

When I was at the MVP Global Summit back in March we saw an early preview of a SearchDataSource.  This looked really cool, but something I would probably not use. 

Oh, how quickly things change!

I've been doing a couple of sites lately that use MondoSearch - Internet and Intranet.  It's a great product and very powerful, but it takes a little while to figure out the best way to use it.  There are a few different api's you can choose from (cgi, ActiveX, .Net Provider and .Net Web Service) and each of these provides different features and supports different scenarios.  After a bit of experimentation I found that the web service offered the simplest solution and best features for my particular problem.

Anyway, I was very interested to see if the SearchProvider in the May release of ASP.Net Futures would make things simpler.  So I created a MondoSearch provider and this is what I found.

Creating the provider

This is extremely easy, especially if you already have some code to talk to MondoSearch.  My provider looks like this:

using System;

using System.Collections.Generic;

using System.Text;

 

using Microsoft.Web.Preview.Search;

using System.Data;

using System.Collections.Specialized;

using System.Configuration.Provider;

 

namespace Jonesie.Search

{

  /// <summary>

  /// An ASP.Net search provider for MondoSearch

  /// </summary>

  public class MondoSearchProvider : SearchProviderBase

  {

 

    private string _licenseKey;

    private string _url;

    private string _mql;

    private string _lang;

    private bool _preview;

 

    /// <summary>

    /// Initialise the search from web.config settings

    /// </summary>

    /// <param name="name"></param>

    /// <param name="config"></param>

    /// <remarks>

    /// The web.config should contain values for:

    /// licenseKey - License key

    /// url - Web Service URL

    /// mql - MQL options

    /// language - language to search on

    /// preview - Use preview database

    /// </remarks>

    public override void Initialize(string name, NameValueCollection config)

    {

      // Verify that config isn't null

      if (config == null)

        throw new ArgumentNullException("config");

 

      // Assign the provider a default name if it doesn't have one

      if (String.IsNullOrEmpty(name))

        name = "MondoSearchProvider";

 

      // Add a default "description" attribute to config if the

      // attribute doesn't exist or is empty

      if (string.IsNullOrEmpty(config["description"]))

      {

        config.Remove("description");

        config.Add("description",

            "MondoSearch Provider");

      }

 

      // Call the base class's Initialize method

      base.Initialize(name, config);

 

      // Initialize licensekey

      _licenseKey = config["licenseKey"];

 

      if (string.IsNullOrEmpty(_licenseKey))

        _licenseKey = "";

 

      config.Remove("licenseKey");

 

      // Initialize url

      _url = config["url"];

 

      if (string.IsNullOrEmpty(_url))

        _url = "";

 

      config.Remove("url");

 

      // Initialize mql

      _mql = config["mql"];

 

      if (string.IsNullOrEmpty(_mql))

        _mql = "";

 

      config.Remove("mql");

 

      // Initialize language

      _lang = config["language"];

 

      if (string.IsNullOrEmpty(_lang))

        _lang = "";

 

      config.Remove("language");

 

      // Initialize mql

      string pv = config["preview"];

 

      if (string.IsNullOrEmpty(pv))

      {

        _preview = false;

      }

      else

      {

        _preview = Convert.ToBoolean(pv);

      }

 

      config.Remove("preview");

 

      // Throw an exception if unrecognized attributes remain

      if (config.Count > 0)

      {

        string attr = config.GetKey(0);

        if (!String.IsNullOrEmpty(attr))

          throw new ProviderException

              ("Unrecognized attribute: " + attr);

      }

    }

 

    /// <summary>

    /// Perform a search against the mondo web service

    /// </summary>

    /// <param name="searchQuery"></param>

    /// <returns></returns>

    public override SearchResult[] Search(SearchQuery searchQuery)

    {

      List<SearchResult> results = new List<SearchResult>();

 

      DataSet msds;

 

      MondoSearch.SearchService ms = new MondoSearch.SearchService();

      ms.Url = _url;

 

      msds = ms.Search(_licenseKey, _lang, _preview, searchQuery.Query, _mql);

 

      // loop through the pages and add them to the results

      foreach (DataRow dr in msds.Tables["pages"].Rows)

      {

        SearchResult sr = new SearchResult();

        sr.Title = (string)dr["title"];

        sr.Description = (string)dr["description"];

        sr.Url = (string)dr["linkdisplay"];

        results.Add(sr);

      }

 

      return results.ToArray();

    }

  }

}

The web.config section for this is:

  <microsoft.web.preview>

    <search enabled="true">

      <providers>

        <add name="MondoSearchProvider" type="Jonesie.Search.MondoSearchProvider, Jonesie.MondoSearchProvider"

            licenseKey="xxxxxxxxxxxxxxxxxxxxxxxxx"

            url="http://mysearchsite.com/SearchService/SearchService.asmx"

            mql=""

            language="EN"

            preview="false"/>

      </providers>

    </search>

  </microsoft.web.preview>

Using the Provider

Using the new provider couldn't be simpler.  Drop a SearchDataSource on the page and set the query, attach your repeater to it.  Bind the repeater.  Done. Here's mine:

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
  <title>Untitled Page</title>
  <style>
body {
  font-family:verdana;
  font-size:12px;
}
.result {
  background-color:white;
}    
.title {
  font-weight:bold;
}
.description {
  font-style: italic;
}
    
    </style>
</head>
<body>
  <h1>
    MondoSearchProvider Test</h1>
  <form id="form1" runat="server">
    <asp:SearchDataSource ID="SearchDataSource1" runat="server">
      <SelectParameters>
        <asp:ControlParameter ControlID="queryText" Name="query" PropertyName="Text" Type="Object" />
      </SelectParameters>
    </asp:SearchDataSource>

    <div>
      Search For:
      <asp:TextBox ID="queryText" runat="server" Width="250" Text="" />
      <asp:Button ID="searchButton" runat="server" Text="Go!" OnClick="searchButton_Click" />
    </div>
    <asp:Repeater ID="rptResults" runat="server" Visible="false" DataSourceID="SearchDataSource1">
      <HeaderTemplate>
        <h3>
          Search Results</h3>
      </HeaderTemplate>
      <ItemTemplate>
        <div class="result">
          <div class="title">
            <a href='<%# Eval("Url") %>'>
              <%# Eval("Title") %>
            </a>
          </div>
          <div class="description">
            <%# Eval("Description") %>
          </div>
        </div>
      </ItemTemplate>
    </asp:Repeater>

  </form>
</body>
</html>


The code behind for the button is:

rptResults.DataBind();
rptResults.Visible = true;

 Limitations & Successes

The main issue I see with the provider is the loss of some of the advanced features of MondoSearch.  For example, security filtering, highlighting, multiple languages - there is nowhere in the SearchResult to store this extra information.

However, using this provider does make it extremely simple to add simple searching to your site.

Sunday, July 22, 2007 12:28:55 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [0]   General  | 
# Monday, July 02, 2007

I can't think of a more worthy MVP Candidate than Alex James. His recent contributions to the Auckland and NZ .Net community have been huge! Congradulations Alex.

Monday, July 02, 2007 5:13:54 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [1]   General | NZ .Net User Group  | 
# Thursday, May 31, 2007
It's been a long time between posts.  I'm currently finishing up a project and moving on to a new client so I thought it would be a good time to document a few things I've (re)learnt along the way.

The project I've been working on is for a large travel web site. In 6 months we have :
  • Replaced the backend web services with WCF services and connected these to new external providers and databases
  • Upgraded the site from .Net 1.1 to .Net 3
  • Replaced 60% of the pages and changed the rest
  • Added significant AJAX functionality and lots of client scripts (JavaScript)
  • Fixed numerous issues and bugs
Here's a list of my lessons in no particular order.

MS AJAX
The new pages are composed of many integrated user controls, some of which use ajax functionality.  UpdatePanels can cause grief to client side functionality and tracing the interaction can be a nightmare.

Tip:  Keep it simple! Only put update panels at the page level.  Only have PageMethods and WebServices called from the page.  Use properties and events in user controls to bubble up control to the page - or better yet use a strong MVP or MVC pattern.

ASP.Net server controls can also frack with your brain. I would love to try creating a site totally without server controls and just use AJAX.

I Love JavaScript
I could do it all day!  Langauges like C# & VB.Net are certainly rich and powerful but JavaScript is small and elegant.  Of course, you wouldn't want to debug a 5000 line JS file too often (and we had a few of those!).

WCF
WCF is very easy to use and configure but you can end up with some huge network traffic issues very easily.  Try to keep your data contracts as small as possible.  Compression helps.

Visual Source Safe
Dont use it if you have any choice.  Don't get me wrong, I actually like VSS for small 1 or 2 developer projects.  My biggest issues are:
  • Exclusive checkout is a real PITA with devs in another room or building.  Sure, you can do non-exclusive checkout but...
  • It still doesn't play nicely with Visual Studio at time.
  • It's slow
  • I don't trust it because it does some really weird things
Task Tracking
This project would have benefited hugely from having Team System available.  I really miss not being able to create work items when I find something wrong or need to remember something to do later.  We are suffering at the end of the project because a few issues had been forgotten or deferred.
Of course, you don't need VSTS to track your todo's but make sure you have somewhere to record things on the fly. Don't use email to tell your BA or PM - they are just as forgetful as you are!

Environment
Also take the time to setup a decent development and test environment BEFORE you start coding.  We lost many days due to problems with the development server - too many projects using the same server, poor performance, lack of control etc.

Web Application Projects
The file based web projects are ok for simple things but Web App Projects give you settings and properties and a few other nicities.  I'm stuffed if I know why MS ever dropped them from VS 05.

CSS & HTML Must Die
There has got to be a better way.  CSS & HTML are ridiculously imprecise.  I'm yet to meet anyone who can sit down and design a web page from scratch that is gaurenteed to work on all browsers and look like they expect it to (except for the simplest of pages).  I'm sure there are a few genius designers out there you can do this, but they are few and far between.

FireFox & FireBug
FireFox with Firebug is an awesome development tool for client side debugging.  You can use FF to debug from Visual Studio by specifying it as the external startup program in your project web settings.

Be Stong. Stay True
Sometimes you are asked to do things that you know are wrong.  A good argument does not always convince a closed mind.  Stay true to your beliefs but do what they want anyway - safe in the knowledge that you will have the last laugh.

Thursday, May 31, 2007 12:43:35 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [2]   General  | 
# Friday, May 11, 2007

Creating deployment documentation for .config file changes is a freek'n nightmare and something that should be automated as much as possible.  I haven't found a tool that does this completely as I want but there's a number of XML Diff'ing tools around that do the hardest part of the job.  I just found this one on MSDN.  It's a little old now but it comes with source and it's fast and simple. 

Ideally I'd like to be able to have XMLDoc comments in .config files and then generate some help from this - much like you can do with NDoc or Sandcastle for your code files.

Friday, May 11, 2007 3:54:40 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [0]   General  | 
# Sunday, April 15, 2007

Enough is enough.  Outlook 2007 on my Notebook is just way too slow and bloated.  In fact it's also causing me greif on my work desktop.  I'm sure it's hardware and/or OS related (Vista on the Notebook and 2003 at work) but I just cant be bothered any more. 

So, I've migrated my domain email to Google Apps so I can dump Outlook.  Time will tell if this was a good move or not - I'm not a fan of using Web apps for mail and desktop type work but there doesn't seem to be any other choice.

The only problem I have now is hooking up dasBlog to Google Mail.  I sometimes use email to post blog posts but I generally use Windows Live Writer.  I can't get this working with dasBlog 1.8 at present - the SMTP notifications also fail.  If anyone out there knows the settings to get this working,I'd love to know!

Sunday, April 15, 2007 3:17:10 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [5]    | 
# Wednesday, April 04, 2007

We are still hiring like crazy - or at least we would be if there were enough suitably skilled developers around.  It makes it really hard to hire with so many great employers - now is a fantastic time to be looking for a development job!

If you are interested in working for Intergen then please don't be afraid to give me a call or email and I'll tell you what a fantastic company Intergen is.

Wednesday, April 04, 2007 3:18:05 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [4]   General  | 
# Monday, April 02, 2007

Unless it was an April Fools email, I was re-awarded MVP status over the weekend.  Once again, I am very grateful for the recognition for doing things I just enjoy doing.

However, this is likely to be my last award as I'm pulling back on my user group and community involvment this year.  Life is too complicated and I dont have the time and energy to do a good enough job.  My wife also tells me I need to get a new hobby so I'm thinking about building something...  not sure what yet, but I have a few ideas.

Monday, April 02, 2007 12:24:47 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [2]    | 
# Sunday, April 01, 2007

Resharper is great. It includes so many neat tools and shortcuts that it really is hard to argue that it's the best Visual Studio productivity tool available today.

So - why do I hate it so much?

1:  A lot of the tools are better versions of the standard Visual Studio versions - refactoring, templates/snippets etc.  I find the VS versions good enough.

2:  There's 3 pages of keyboard short cuts to remember if you want to use Resharper effectively.  I have enough trouble remembering Ctrl+C to copy.

3:  It's sooooo f-ing slow!  VS runs like a complete dog when Resharper is installed.  All those productivity gains are pointless if you are waiting for VS to respond.

4: It's noisy.  I like VS clean and simple.  I dont like all the Reshaper crap over the screen interfering with my train of thought. 

5: It's a little buggy - well, I cant say this for sure, but I think it suffers from trying to be too clever and sometimes it gets things wrong, especially with ASP.Net tags.

So, this time I managed to keep it on my machine for 3 days before removing it.  I'll try it again in another couple of versions.

Sunday, April 01, 2007 10:15:26 AM (New Zealand Standard Time, UTC+12:00)  #    Comments [1]    | 

I'm back into VSTS with a vengence this week and I just read some announcements that I heard at the Summit that now appear to be public.

Unit Testing to be included with Visual Studio Pro

I never understood why it wasn't in pro to start with - my personal opinion is that it was interference from Marketing that drove this decision.  Thankfully, Marketing also took note of the thousands of complaints and they have done the right thing.  I fear it's too late though.  Most dev's I know prefer NUnit.  NUnit and it's add-on's have progressed a lot in the last couple of years so it's going to be hard for TS Unit Testing to regain ground.  I'll be using it though - mostly for compatibility with Team Build.

Orcas & Rosario (VSTS v Next + 1)

Looking at the road map for Orcas it's pretty clear that Orcas will RTM sometime towards the end of this year.  This is the message we got at the Summit.

Rosario includes a lot of new features to help with bigger teams and projects. Some of the features will be really useful for ISV's such as Intergen - we find it an ongoing battle to calculate future resource requirements.  Having a tool that will help do this will be very useful.

TeamPlain

Microsoft has acquired TeamPlain, a web client that provides access to work items, source control etc.  This is fantastic news!  I love TeamPlain but could never justify the extra expense of it.  Now I wont need to.  Event better, I can get it now!

Sunday, April 01, 2007 10:06:30 AM (New Zealand Standard Time, UTC+12:00)  #    Comments [0]    | 

Just spotted this MSDN article on Asynchronous ASP.Net coding.  It's a must read for ALL ASP.Net devs - weather you are creating a TradeMe killer or MySillyLittleSite.com.

Sunday, April 01, 2007 9:31:46 AM (New Zealand Standard Time, UTC+12:00)  #    Comments [0]    | 
# Wednesday, March 28, 2007

Highlight:  Utah - most any part of Utah is stunning and truly awesome.  The desert is beautiful and quite unique to a Kiwi - we don't really have any deserts here.  Bryce, Glen Canyon and Zion National Parks are very pretty but I wouldn't want to be there in busy season.

Lowlight: Las Vegas.  It takes about 1 hour to realise what a scummy place it really is. On the outside it looks interesting but as soon as you walk into any of the hotels on the strip they all look identical - full of sad pathetic losers glued to brain washing machines.  I just hate all casinos...

Highlight: The people are friendly and actually quite normal! 

Highlight: Apart from Seattle the weather was clear and hot - which is apparently unusual for March.

Lowlight: San Francisco - I feel violated!  For a big city it's not bad but we had a hotel in a very seedy part of town and we were constantly pestered by street bums, beggars and people trying to sell stuff.  Waiting in line for a cable car we were hassled by 'entertainers' and beggars - not my idea of a great time.

Highlight: Seattle - despite the weather I like Seattle.  It has a nice feel to it despite having it's fair share of street people.  I didn't feel as taken advantage of as I did in San Francisco.  The pace seems more relaxed there too.

Lowlight:  Grand Canyon.  From the air this is breath taking but like most of the USA, it takes more time to absorb than most people have in a life time.  We only had 2 hours to spend looking over the edge but I felt it was too commercially exploited compared to Bryce or Glen Canyon. 

Lowhighlight: It's not that expensive.  It's a lot cheaper than Europe or the UK for a holiday and certainly very easy to get around.

Highlight: Driving in the USA is a joy.  The roads in Utah, Nevada and Arizona are long, wide, mostly straight and not too busy.  We drove about 1100 miles from Salt Lake City to Las Vegas in 6 days. Our biggest trip was about 450 miles on the first day which was a very leisurely 8 hour drive.  Sticking to the wrong side of the road was a lot easier than I thought it would be.

We spent most of our time in the Utah desert so overall, it was very happy experience - the lowlights of Las Vegas & San Francisco where very minor in comparison.  We are thinking about Vancouver and/or Colorado for the next trip - once we pay for this one.

Wednesday, March 28, 2007 9:51:16 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [1]   General  | 
# Monday, March 26, 2007

I’m a little late blogging about the MVP Summit – it finished on the 15th – but I’ve only arrived home yesterday.  The wife and I took the opportunity to do some tripping around – more on this later.

The Summit this year was great.  It was very well organized, the venue’s – Seattle’s Convention Center & Microsoft – were spacious and accessible.  Transportation was very easy and well organized this time.

As usual, we also got to here from some great & famous speakers, including: Bill Gates, Anders Hejlsberg & Scott Guthrie – all of which were highlights in one way or another.  We also got to learn about a few upcoming products and new releases – much of which I cannot repeat here – but here’s a few teasers.

  • Orcas – there are a lot of nice new features and enhancements in this – particularly around testing, Javascript, AJAX, design etc.  Debugging and development Javascript is a place I am very keen to see enhancements on and we saw some nice demos of improvements in these areas (including a fix for a long running complaint from many people).  I think the March CTP has some or all of these features included already so check it out.
  • ASP.Net v Next – Scott talked about and demo’d a few new features of the next version of ASP.Net in Orcas.  Again, I think this stuff is probably in the March CTP but without looking I’m not willing to risk the lawyers!  Lets just say that you will see more code-less provider model type things a some new controls that will save you a LOT of coding.
  • LINQ – Anders did a great demo of LINQ for Objects & SQL.  If you have been living in a cave and not heard of LINQ or have been ignoring it then RUN – don’t walk – to your nearest search engine and learn as much as you can about it now!  LINQ will change the way you work with objects and data in ways you may not have realized… eg PLINQ.
  • AJAX – Scott demoed some of the new Orcas features for AJAX.  He also detailed some features of the current release I was unaware of, including pageLoad().  There’s a great blog post here that shows how to use this and some other nifty features.
  • Team System – Rosario is the code name for VSTS after Orcas.  There’s not much public information on this so I can’t say anything but the very few tidbits I did here about it sounds intriguing. Use your imagination and look at some of the research and tools the team has been talking about and you will get a fair idea of where they are heading.
  • Lastly, some estimated delivery schedules were mentioned for Orcas & Longhorn… and I’m certainly not going to repeat those but it’s safe to say – I think – that by this time next year I’ll be blogging about Orcas SP1 :]
Monday, March 26, 2007 8:55:14 PM (New Zealand Standard Time, UTC+12:00)  #    Comments [0]   General | Team System | Visual Studio  | 
# Friday, February 09, 2007
Here's the sample code from User Group demo I did this week on using JSON & ATLAS to create lightweight asynchronous web pages.
 
Enjoy!
 
JSON.zip (20.48 KB)
Friday, February 09, 2007 5:12:17 PM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   General | NZ .Net User Group  | 
# Monday, February 05, 2007
Free ASP.Net Refactoring Tool by peter@jonesie.net.nz

Dev Express have just release a free refactoring addin for ASP.Net code and Visual Studio 2005.  You can get it here:

 

http://blogs.msdn.com/webdevtools/archive/2007/02/02/free-refactoring-tools-for-asp-net-code-in-visual-studio-2005.aspx


 

Monday, February 05, 2007 8:36:12 PM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   General  | 
If you are into small devices in a big way then you should take a look at the new .Net Micro Framework, which will be released very soon.  You can run this on your watch or similarly tiny devices as long as you have 300k RAM and 1M flash.  There is a LOT of stuff missing from the MF but you generally wont want to do most of that sort of stuff - e.g., database access. As with the compact framework you can use Visual Studio to create, compile and debug via emulators, then deploy via USB or serial connections.
 
One aspect of this I find very intriguing is that the MF is self bootable - i.e., you don't need and OS. 
 
Can you think of a use for this?
Monday, February 05, 2007 1:48:58 PM (New Zealand Daylight Time, UTC+13:00)  #    Comments [1]   General  | 
# Friday, February 02, 2007
According to RNZ this morning rumors are spreading - again? - that Telecom's CEO, Teresa Gattung, is very likely to quit the job soon.  Under her guidance, the company has managed to nearly halve it's share price, alienate a nation, invoke legislation, relegate us to 3rd world status and generally piss off a lot of customers and staff.
 
Well done Teresa!  You've earned a nice long retirement.
 
UpdateShe's gone! 
Friday, February 02, 2007 7:58:36 AM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   Business  | 
Next month I'm off to the Global MVP Summit.  This is a semi annual event for MVP's and provides the opportunity to meet with the product teams - yes real Microsoft developers and managers - plus some of the top execs.  This year, Bill Gates is presenting the keynote - last time, Oct 2005, it was Steve Ballmer. 
 
So, I've been thinking a lot about what I want to see and say during this 4 day pilgrimage. Here's my list thus far.  I'd love you to add to it!  Tell me what is important to you and I will endeavour to ask the right people and get an answer.
Orcas
 - anything about Orcas, esp. Team System.  At the 05 summit we where asked about some of the wizz bang new stuff they were thinking about putting into Orcas and beyond.  It will be interesting to see how much of these ideas made it to a real product.  At the time I was very excited by some of these ideas, particularly in the debugging area.
 
SQL Server v next
- it's hard to see how they could improve on SQL 05 in any major way but apparently the next version is under development.
 
- what's the future for WF, WCF & WPF?
 
- the expressions tools are very impressive.  How will these fit in a development team currently using Visual Studio?  Yes, I understand the promise but it would be good to here about the reality.  I seriously worry about mixing developers and designers :)
 
Languages
- C# 3 is changing in many ways.  The language gods are certainly taking note of functional and dynamic languages.  It's hard to separate the language from the tool some times - i.e., what is C# like if you only have Notepad ?  Will it be impossible to use C# 3 or VB 9 without Visual Studio or one of it's spin offs? Not that I would dream of doing this you understand, but I think it's an indication of the level of purity in the language.
 
AJAX & JavaScript
- I have a few issues with AJAX and the Asp.Net platform.  I need to know if this is just me or not.  Also, I have an idea for working with JavaScript in Visual Studio - I'd like to see if Microsoft have the same idea.  I'd like to have Visual Studio provide better support for js files - the intellisence is not as good as it could be, but more importantly I'd like to have .JSX files - these would be JS files but with the ability to include server controls and markup (<% %>).  So you'd have a CS or VB code behind file for them - this could also be the same code behind as the ASPX/ASCX that uses the JSX file.
 
Software Factories
- we have software factories for web services, web sites, smart client.  What's next?  What about EFx? I'd like to see this in action.
 
Can you add to this list?  Please comment and let me know.
 
Oh, just remembered.  Most of what we discuss and see at the summit is provided under a non disclosure agreement so I can ask your questions, but I may not be able to tell you the answer - at least not precisely :)
Friday, February 02, 2007 7:42:12 AM (New Zealand Daylight Time, UTC+13:00)  #    Comments [1]   General  | 
Well, not really free, but a great way to get Vista or Office is to attend the 2007 Technical Briefings.  There are some good looking sessions there for developers.  I'd reccommend attending the Sharepoint sessions in particular.  This is a fantastic platform for back-ending many types of applications - it's not just for departmental intranets.
 
It's also a great event to smooze with local devs and business people.  Unfortunately, I'll be out of the country for most of March so will miss it.
Friday, February 02, 2007 7:12:07 AM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   General  | 
# Friday, January 26, 2007
ATLAS RTM by pjones@hot.co.nz
Go get it now!  ASP.Net 2.0 AJAX Extensionis officially RTM. 
 
There's a few minor changes from the release candidate, most notably the removal of the validation controls, but it's a pretty simple upgrade.
Friday, January 26, 2007 8:04:33 AM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   General  | 
# Thursday, January 25, 2007
Yet another reason to use IIS and not the built in web server in Visual Studio (Cassini).  I have some PageMethods I'm calling from the page that tell me the progress of a search.  In Cassini these calls queue up while the async search methods are running becuase it does not know how to handle multiple requests concurrently. 
 
Also, Cassini always has Windows Auth turned on.  It ignores the NTLM Auth setting in your project.
 
I do find Cassini fine for simple web pages though and I use it on my notebook for small site development without problems.
Thursday, January 25, 2007 12:15:07 PM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   General  | 
# Monday, January 22, 2007

Well, the ‘5 things about me tagging game’ has finally caught with me, thanks Darryl.  I did miss your link though as I’ve been spending a lot of time lately getting Vista working sweetly, working on a couple of web sites and preparing a presso for the local .Net User Group - which conveniently gave me plenty of time to think about the 5 things – just in case I got asked.  So here goes.

  1. I lived in Sydney for a while in my youth and drove a cab for a year.  Famous fare’s included Tim Finn, Barry Humphries (thankfully not in costume) and Yana Vent (spelling?) (but you have to be Australian to know her).  Other interesting jobs include TV Aerial Installer, Bakers Assistant, Storeman, Egg Collector, Night Porter, Barman, Bouncer, Telephone ‘Operator’.
  2. I live about ½ an hour out of Christchurch and have a lifestyle block with 500 or so olive trees, 3 kids, 8 chickens and 2 cats.  Oh, and a wife :]
  3. I seem to get sucked (?) into starting user groups and community ‘things’.  I started the Christchurch Clipper User Group back in the early 90’s and I STILL think Clipper is a great development language.
  4.  Most exotic(?) place I’ve been to would be Brunei.  My most favorite city?  Have to be Florence.  I spent a few days there about 18 years ago.  Definitely want to go back and see more of Italy.  Scariest place I’ve been? Johannessburg at night.
  5.  I hated school.  I’ve never attended university and didn’t get UI either.  Consequentially, my kids get off too easy from homework.

I’ll need to do some research to see who hasn’t been tagged yet.  I’ll update this post later.

 

Monday, January 22, 2007 10:33:21 PM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   General  | 
# Monday, January 15, 2007
I've been doing a lot of fun JSON stuff lately using ASP.Net AJAX (aka ATLAS).  This really is Fun with a capital 'F' but I struck a small problem today.
 
Given the following C# class:
public class PageData {
 
    public string Name;
    public string Address;
    public DateTime DOB;
 
    ...
 
}
I serailize this to the page thus:
 
C#
 
    protected void getPageData() {
        PageData pd = new PageData("Peter Jones", "New Zealand", DateTime.Now());
        return "(" + JavascriptSerializer.Serializer(pd) + ")";
 
    }   
 
ASP:
 
    <DEFANGED script type="text/javascript">
        var pagedata = eval('<%= getPageData() %>');
 
    </script>
 
Now this works fine for all data types except DateTime.  When you serialize a DateTime you get a value in JSON like this:
 
    @7895678963897@
 
This is the number of milliseconds since 1 Jan 1970.  When this is de-serialized with eval() you just get a string. 
Instead of using eval() you need to use Sys.Serialization.JavaScriptSerializer.deserialize().
 
For reference see:  nikhilk.net and Hannes Preishuber
 
Update
 
This appears to have changed in the RTM release.  Dates are now serialized thus:  /Date(millseconds)/.  However, I cant get this to deserialize using Sys.Serialization.JavaScriptSerializer.deserialize() so have reverted to using a string in yyyymmddThhmm format, which Date.parse() will happily convert.
Monday, January 15, 2007 8:34:28 AM (New Zealand Daylight Time, UTC+13:00)  #    Comments [0]   General  | 
Copyright © 2013 Peter G Jones. All rights reserved.
DasBlog 'Portal' theme by Johnny Hughes.
Pick a theme: