• Updating assembly versions in Visual Studio project files

    Sometimes you need to update all the references to a particular assembly so that they use a newer version than the original one that was added to the project.

    One option is to manually edit the references for each project, removing and re-adding the assembly.

    Option two, which is a bit nicer, is to use something like this PowerShell script:

    Get-ChildItem -recurse -filter "*.*proj" | Foreach-Object { (Get-Content $_.FullName) | Foreach-Object { $_ -replace "1.0.3.0", "1.1.0.0" } | Set-Content $_.FullName }

    In this example, we are replacing instances of "1.0.3.0" with "1.1.0.0" – handy if you just happened to be upgrading to the latest version of Castle.

    Note the use of the parentheses () around the Get-Content - without those you'll end up with an Access Denied error as it will be trying to write to the same file it is reading from.

  • CodeCampSA 2009 – Day 2

    Presentation notes

    Nigel Spencer – WPF in 2010

    • Easing functions – affect animation velocity
    • Behaviours
    • Demo of customising Visual Studio home page – XAML-based
    • Model View ViewModel – templates

    Greg Low – Spatial SQL

    • sys.spatial_reference_systems

    Dave Glover – Windows 7 APIs

    • Windows 7 Training Kit

    Omar Besiso

    • Sync Framework (seemed strangely familiar!)

    Jason Stangroome – PowerShell and build automation

    Jason Schluter – Silverlighter

    • XHTML to Silverlight converter

    James Chapman-Smith – Model View ViewModel and Unit Testing

    • ViewModel handles
      • UI logic
      • input validation
    • Thought while observing Jame's code – could you have INotifyPropertyChanged take a lamba expression instead of a string? – Apparently yes!

    Peter Cornish – AdWords

  • CodeCampSA 2009 – Day 1

    Presentation notes

    David Gardiner – Generating Unit Tests with Pex

    • Fantastic
    • Inspirational
    • I wish I could present like this guy
    • :-)

    Anthony Borten – TFS 2010

    • Always try to install TFS, SharePoint and Build on separate servers if possible
    • Make sure you launch config tool immediately from the installer
    • Note the 'test' buttons to check your server names
    • Team Foundation Administration Console
    • Branching – better in 2010
    • Team Build
      • Build controller
      • Build agent
      • Gated checkins

    Allan Baird – UniSA

    • Industry partnerships – opportunities to have students work for 6 or 12 month placements.

    Rob Farley – The problem with BEGIN and END in T-SQL functions

    • Useful tool - "fences" – hides desktop icons
    • Generally modularisation in T-SQL is good
    • Funny joke about COUNT(dracula)
    • Compare two queries – one using a user-defined function, the other just has SQL
      • function query appears to run faster according to query plans
      • BUT, using SQL Profiler, it is actually much less efficient
      • SQL sees BEGIN/END and can't inline the function

    Liam McLennan – MVC is better than WebForms

    • WebForms is to imperial as MVC is to metric

    Tatham Oddie – WebForms are better than MVC

    • Used WebForms for graysonline
    • Used application/xml mimetype to validate XHTML content with Firefox during testing
    • XHTML 1.1 templates for Visual Studio
    • Tool to convert bad HTML to valid XHTML
    • .NET 4.0 – Can disable page-level ViewState, but enable it on specific controls

    Scott Barnes – Silverlight

    • Was a Flash developer before joining Microsoft
    • 400 million downloads of Silverlight
    • Biggest competitor - HTML+JS!

    Anthony Borton – VSTS 2010

    • Eliminating no-repro bugs
    • Virtual Lab Management
    • Test Case Management
      • Record against real application
      • Fast forward through test steps
    • Microsoft Test and Lab Manager
    • Replay – re-run test including launching application under test
    • Coded UI Test
      • Test builder – records UI actions

    Paul Turner – SharePoint branding tips and tricks

    • Start with minimal master page
    • Enable debugging
    • Position tool pane
    • Standard delegates (My Site etc)
    • Site actions
    • Digest (MAC)
    • Understand CSS
      • Add custom CSS with CssRegistration
    • Don't put JS in master page
    • Async JS with defer