Martin Hinshelwood's Blog

A Scottish dyslexic software developer: .NET architect, developer, evangelist, technology enthusiast and multi-dimensional free thinker


News

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

Subscribe

Personal

Accreditation

Stats

My Stats

  • Posts - 255
  • Comments - 285
  • Trackbacks - 67

Twitter












Tag Cloud


Recent Comments


Recent Posts


Article Categories


Archives


Post Categories


Image Galleries


Blogs I read


Blogs of Friends


Blogs on VSTS


Multi-Dimentional Free Thinking Bloggers


Personal


Projects


February 2008 Entries

Loss of My.User.Name is not that bad...


Imports System.DirectoryServices.AccountManagement

In WPF development you can't just use the "My.User.Name" classes as it is not set by default. If you still want to use it you can "My.User.InitializeWithWindowsUser()" to have it setup, but there is a better way.

If you are using Active Directory .Net 3.5 has provided a new way to access information...

There is a new assembly called "System.DirectoryServices.AccountManagement" that encapsulates all of the logic for accessing security information in a number of ways.

You can create a link to your local Active Directory  by calling:

 Dim ctx As New PrincipalContext(ContextType.Domain)

The options for conencting are:

  • ApplicationDirectory - The application directory store. This represents the AD LDS store.
  • Domain - The domain store. This represents the AD DS store.
  • Machine - The computer store. This represents the SAM store.

These options allow for most security authentications in your .NET applications, and it does not stop with wrapping the top level AD. if you want to access and control a user you need only:

Dim u As UserPrincipal = UserPrincipal.FindByIdentity(ctx, IdentityType.Sid, WindowsIdentity.GetCurrent.User.Value)

I really like this as often I have has to build and Google (more the later than the former) class library for manipulating Active Directory objects, and you need not just use the Sid. You can use:

  • DistinguishedName - The identity is a Distinguished Name (DN).
  • Guid - The identity is a Globally Unique Identifier (GUID).
  • Name - The identity is a name.
  • SamAccountName - The identity is a Security Account Manager (SAM) name.
  • Sid - The identity is a Security Identifier (SID) in Security Descriptor Definition Language (SDDL) format.
  • UserPrincipalName - The identity is a User Principal Name (UPN).

And this is just the direct load of a user object. There are Group object as well as fill search capability with the PrincipalSearcher and various other bits and bobs...

Well thats my find of the day smile_nerd

 

posted @ Tuesday, February 19, 2008 1:09 PM | Feedback (0) | Filed Under [ Microsoft .NET Framework ]


Waffling on SharePoint...


Documentation, documentation and more documentation.. The life blood of IT. The only problem being that it is very difficult for a technically minded individual such as myself to write documentation with NO technical content what so ever! These documents are what the business really want; They do not care that the workflow capabilities of SharePoint bring easer workflow to the masses, they only care that it is there; They do not care that we will be deploying on 2 front end servers with 1 application server and a database server for the first initial farm, they only care that it will work.

With this in mind how do you impress upon them the potential of the system? Well... you don't, you can only build a system with the capabilities that you think they will need and once you get down to the details of migrating their applications will you actually get any meaningfully feedback..

That is the advantage of using SharePoint. It can do pretty much anything: If not out of the box, then you can build on it, or get contractors to work on it...

Its all about standards...

 

posted @ Tuesday, February 19, 2008 8:37 AM | Feedback (1) | Filed Under [ Microsoft Windows Personal Sharepoint Work MOSS Time Off Management MOSS ]


TFS Sticky Buddy POC (WPF) release


image You can now Download the TFS Sticky Buddy windows presentation foundation proof of concept demo from the Codeplex site.

This is a proof of concept release of the Team Foundation Server Sticky Buddy digital dashboard project that is built using Windows Presentation Foundation (WPF). This is the main version of the application as the WinForms version of the application has been deprecated. There are some layout issues with this version, but they should be fixed fro the next release. The source code is provided with the installation.

Usage

When the sample starts you will need to select a team foundation server from the list (if you do not see any servers then you must set them up using Team Explorer) which will populate the Projects list. Once you have selected a project the dashboard will be rendered.

System Requirements

  • .NET Framework 3.5
  • Visual Studio 2008 Team Explorer

Give it a go, and let me know how you get on.... You can also get a WinForm version of the application.

 

posted @ Monday, February 11, 2008 10:28 AM | Feedback (4) |


TFS Sticky Buddy POC (WinForms) release


You can nowimage Download the TFS Sticky Buddy windows forms proof of concept demo from the Codeplex site.

This is a proof of concept release of the Team Foundation Server Sticky Buddy digital dashboard project that is built using Windows Forms. This version has layout issues, but is provided as is for demonstration use. The extent of the layout issues will depend on your Area and Iteration layout within the selected project. The source code is provided with the installation.

Usage

When the sample starts you will need to select a team foundation server from the list (if you do not see any servers then you must set them up using Team Explorer) which will populate the Projects list. Once you have selected a project the dashboard will be rendered.

System Requirements

  • .NET Framework 3.5
  • Visual Studio 2008 Team Explorer

Give it a go, and let me know how you get on....WPF version to follow...

 

posted @ Monday, February 11, 2008 9:44 AM | Feedback (2) | Filed Under [ Microsoft .NET Framework RDdotNET Visual Studio Team System Work TFS Sticky Buddy ]


TFS Sticky Buddy layout fun...


TFS Sticky Buddy (WinForms) Screenshot I had a lot of fun trying to lay out my TFS Sticky Buddy project using Windows Forms, and eventually decided that it was way to fiddle doing it in a Forms based application. It was not just that tables and panels don't work as I expected, but that there were way to many bits that were more difficult than they should be. This is mostly down to my inexperience and down right ineptitude with graphics and UI's, but it still should not be this hard. smile_baringteeth

I know that the picture on the right is not pretty, and the colours I have picked are pretty random to help solve the layout issues, but the application works....

The problems, as you can see from the image are layout ones. I tried the FlowLayoutPanel, but I could for the life of me, not get the bloody boxes to stretch to fit the contents. Then I used the TableLayoutPanel, and ran into what you see above...Yeuch smile_sniff (Scottish for Yuck (Like Loch)).

I guess I spent too much time doing web development when I was younger, but now when I try to go back to web based stuff I always end up shouting and swearing at the html layouts and growling at the post-back functionality...

What I needed was something that was a cross between Windows Forms, and Web Forms. Something that had good layout functionality, but without the messing around necessary with HTML and CSS. You see, I like HTML and CSS, except for one little thing... It never does what you tell it. At least forms do what you tell them, and that is sometimes the problem with forms, they do ONLY what you tell them.smile_teeth

I had only spent a day on the application so far, so I was not overly concerned about the loss of time. I had chosen Windows Forms because I knew it, but deep down I knew that Windows Presentation Foundation was the way to go, I was just scared of the steep clime of understanding...smile_nerd

TFS Sticky Buddy (WPF) Screenshot Sod it...Of I went with a WPF version... And the result were impressive. Not only have I only spent a day and a half on it, but the immediate learning curve is a lot smaller than I though. Sure, you can add styles and templates among other things, but to get what you get with Windows Forms (only prettier) takes less time, not more, even with the learning curve (but I guess that is dependant on how quick you are smile_wink). And I am sure that once I master the other functionality provided in WPF it will become much easer.

Sure, if you look at the image for the second WPF version you will still see layout problems, but they are minor and fixable (although I am not sure how yet), and the whole thing was a more painless to tweak.

I will try to release these two versions along with the source code today, but just as a POC (Proof of Concept) to show the potential of the application.

I want to have nice little callouts of information when you move your mouse over a work item or Area/Iteration, and I am continuing to work on it....

 

Technorati Profile

posted @ Monday, February 11, 2008 8:51 AM | Feedback (0) | Filed Under [ Microsoft .NET Framework RDdotNET Visual Studio Team System Work TFS Sticky Buddy ]


TFS Sticky Buddy Codeplex project


I hade been looking with envy at the digital whiteboard experiment, and with dismay at the lack of open source for the project. So...

DigitalWhiteboardJune2007 I will be creating a version of the that will run off Team Foundation Server and allow teams to display information on the status of their development on one or many projects.

The application will be able to be displayed on a projector or large TV screen. The application will consist of a main screen that queries a TFS Server and pulls a list of projects that the user can select for display and within each project it will display the iteration tree. This tree will be displayed as a set of concentric columns that are populated with "Change Requests" and "Requirements" that are currently within that iteration path.

Each of the Work Items displayed will show limited information about itself, which user it is assigned to, its Area and title. But it will also display the number of sub items within each item. This will give an indication of the length of time necessary to complete all of the sub-work items within that iteration so it can be moved on to the next.

A set of rules will determine the colour or icons associated with each item based on their status. These rules may include: 

  • Is this item overdue?
  • Does this work item have any blocked work items associated with it?
  • Does this work item have any risks associated with it?

The resultant Digital Whiteboard will be displayed in our main offices so we will be dogfooding :)

 

posted @ Tuesday, February 05, 2008 11:32 AM | Feedback (11) | Filed Under [ Microsoft .NET Framework Visual Studio Team System Personal Work TFS Sticky Buddy ]


I always wanted to be an Admiral!


Having just watched the entire 3rd series and waiting with bated breath for the 4th and final season, I could not resist this quiz...

I know...I'm a bit sad...

 

Technorati Tags: ,

posted @ Sunday, February 03, 2008 11:26 PM | Feedback (0) | Filed Under [ Personal ]