>
 Thursday, February 28, 2008

I'm in the middle of preparing for a session at SD West next week where I talk about the Microsoft Technology Roadmap - basically an avalanche of technologies in one day. Each time I present this I have to update my resources with newer tools, usually extensions to Visual Studio environment, so that attendees can be successful at running demos.

Here is my latest list of "setup instructions" for the CTPs I use, with links to where the sites are located. I can't guarantee how long these will be the latest, but you should be OK for at least the next month!

Windows XP/SP2 or Windows Server 2003 Setup

This section describes core machine setup for the operating system, .NET 3.0 and SQL Server.

· Enable IIS

· Enable MSMQ

· Install .NET 3.0

http://www.microsoft.com/downloads/details.aspx?FamilyId=10CC340B-F857-4A14-83F5-25634C3BF043&displaylang=en

· Windows SDK Update for Vista (really, for .NET 3.0)

http://www.microsoft.com/downloads/details.aspx?familyid=4377f86d-c913-4b5c-b87e-ef72e5b4e065&displaylang=en

· SQL Server 2000/2005 or SQL Express

o Install any service packs

Windows Vista/SP1 or Windows Server 2008

This section describes core machine setup for the operating system, .NET 3.0 and SQL Server.

· Enable IIS/WAS

· Enable MSMQ

· NOTE: .NET 3.0 is already installed

· Windows SDK for Vista (really, for .NET 3.0)

http://www.microsoft.com/downloads/details.aspx?familyid=4377f86d-c913-4b5c-b87e-ef72e5b4e065&displaylang=en

· SQL Server 2000/2005 or SQL Express

o Install any service packs

Visual Studio 2005 (if you have to)

This section lists tools to install to set up your Visual Studio 2005 environment. For .NET 3.0 and 3.5 development, Visual Studio 2005 is sorely out of date on tools, so anything you install from this list below is likely not to work with newer code samples. You have been warned.

· Visual Studio 2005 Extensions for WCF and WPF – November 2006

http://www.microsoft.com/downloads/details.aspx?FamilyId=F54F5537-CC86-4BF5-AE44-F5A1E805680D&displaylang=en

· Visual Studio 2005 Extensions for WF – November 2006

http://www.microsoft.com/downloads/details.aspx?familyid=5D61409E-1FA3-48CF-8023-E8F38E709BA6&displaylang=en

· Visual Studio 2005 LINQ CTP - May 2006

http://www.microsoft.com/downloads/details.aspx?familyid=1e902c21-340c-4d13-9f04-70eb5e3dceea&displaylang=en

· Visual Studio 2005 ADO.NET vNext CTP – May 2006

http://www.microsoft.com/downloads/details.aspx?FamilyId=B68F6F53-EC87-4122-B1C8-EE24A043BF72&displaylang=en

· Visual Studio 2005 Entity Data Model Designer Prototype CTP – May 2006

http://www.microsoft.com/downloads/details.aspx?FamilyID=74bda7b2-9ca9-4eea-a33f-31942ddc9dbe&displaylang=en

Visual Studio 2008 RTM

This section lists tools to install to set up your Visual Studio 2008 environment. Many tools have been installed, but there are also many extensions for ASP.NET, AJAX, Silverlight and ADO.NET 3.5 features in this list.

· NOTE: Tools for WCF, WPF, WF, AJAX and LINQ are built-in

· Run this so that older projects will bind to older version of AJAX libraries

http://download.microsoft.com/download/7/9/2/79268325-1006-4566-bd26-5581b8971f36/DisableAjaxPolicy.EXE

· AJAX Control Toolkit for .NET 3.5 (includes the rich code sample for AJAX)

http://www.codeplex.com/AtlasControlToolkit/Release/ProjectReleases.aspx?ReleaseId=4941

· ASP.NET 3.5 Extensions Preview – December 2007 CTP

http://www.microsoft.com/downloads/details.aspx?familyid=A9C6BC06-B894-4B11-8300-35BD2F8FC908&displaylang=en

· ADO.NET Entity Framework Beta 3

http://www.microsoft.com/downloads/details.aspx?familyid=15DB9989-1621-444D-9B18-D1A04A21B519&displaylang=en

· Entity Framework Tools Beta 3

http://www.microsoft.com/downloads/details.aspx?FamilyId=D8AE4404-8E05-41FC-94C8-C73D9E238F82&displaylang=en

· Silverlight 1.1 Alpha Refresh – September 2007

http://msdn2.microsoft.com/en-us/silverlight/bb419317.aspx

· Silverlight 1.1 Tools Alpha for VS 2008 – November 2007

http://www.microsoft.com/downloads/details.aspx?familyid=25144c27-6514-4ad4-8bcb-e2e051416e03&displaylang=en

· Expression Blend 2 Preview – December 2007

· http://www.microsoft.com/downloads/details.aspx?familyid=65177E23-C116-475A-9057-5A5071A379F6&displaylang=en

· ASP.NET 3.5 Extensions Preview – ADO.NET Data Services Silverlight Add-On - December 2007

http://www.microsoft.com/downloads/details.aspx?FamilyID=fd9c2a29-7383-4b2e-9ec9-0c6120718d4f&displaylang=en

 

Technorati Tags: , ,
2/28/2008 5:19 PM .NET 3.0 | .NET 3.5 | Visual Studio | VS 2008  | Comments [1]  |  View reactions  |  Trackback
 Wednesday, February 01, 2006

I blog when I have time and have something important to share, but I don't always have time to blog everything important I have to share (that's what articles and books are for I guess)...sometimes I blog just to hook you up to content references for events I've been part of...but today...I'm just blogging to vent my frustration with code snippet management in Visual Studio 2005. Aaarrrrghhhh...

Don't get me wrong, code snippets rock for productivity, but creating your own and getting them to freaking appear in the right place seems like a feat of great energy and time that I really do not have...sigh...but I took the time anyways because I figure if I just spend 2 hours (or 7200 seconds) now to get it working, then spend and extra 5 minutes (or 300 seconds) creating snippets for my repeatable code...it will pay off after I use about 200 snippets. Assuming I use about 3 code snippets per code sample, and that I create several code samples per day for my WCF book, not to mention other code samples and vertical slices for clients...I should be able to recover this time about 20 days time or less. Of course, I'm not factoring in time to write this blog...

So here goes my experience creating code snippets:

Creating new XML config snippets, no problem at all. Just copied an existing code snippet sample and away we go! Off to a good start.

Adding the code snippet to the Code Snippet Manager. Well first of all, figuring out what Add... versus Import... mean in that dialog is a pain. No, I didn't take the time to read an article about it...and frankly I expected it to be pretty easy to figure out. Well it seemed like sometimes Add worked, sometimes it didn't, but I seem to have finally figured out that you are supposed to select a directory that holds the code snippet type for the language you are adding folders to.

So, I created a WCFSnippets folder with two subdirectories:

\WCFCode -> holds my C# WCF code snippets

\WCFConfig -> holds my XML WCF code snippets for configuration

Then, from the code snippet manager, you select XML for the language and click Add. What you are supposed to do is find the folder with your XML snippets, so I navigate to \WCFConfig...but don't just navigate to that directory, drill all the way into the directory where the snippets are stored before you select the directory. Here are the screenshots: wrong, right and result...respectively.

For C# or VB.NET snippets, just select the right language, and drill into the directory where those are located.

Extra crap in my code snippets intellisense...make no "sense". I know the above seems really super easy...and it is once you know where to navigate and how to organize your stuff. Still, I had all kinds of extra crap left over in my snippet manager, and in my code snippet intellisense...let me explain.

After trying Add/Import, I was left with extra folders in my code snippet manager, that somehow didn't reflect all the snippets I was creating...it was nuts...I was going nuts...maybe I am nuts...anyways it turns out that Import is not really necessary if you have added your snippets folder according to the Add method I explained. Any new snippets you create in those custom folders will now appear in the magical snippets list. But, if you want to copy (import) a snippet from somewhere and put it into one of your folders (or, one of the predefined snippet folders for VS) you can Import.

If I navigate to my WCF configuration snippets folder and select a snippet, I will be presented with the already existing XML folders (preexisting or resulting from Add). You decide where you want the snippet to go and a copy is made there. Watch out for dupes!

The bugger of it is, you can't remove snippets. You can add them, but they will never go away...that is unless you delete the actual snippet from the file folder. So much for snippet management. You can remove folders, just not those living in the VS snippet folder, that's too official to remove...

Things to watch out for.

1. Beware not to add your snippet directories more than once. Or not to add the parent directory, only to decide on the child directory as in my WCFSnippets and WCFConfiguration example earlier. What happens? Well, somewhere out in snippet configuration land (a lost land that I cannot find) there is memory of every (wrong) directory you ever added using Add...and you can't freaking get rid of it. Well...I'm sure you can, but I care not spend more time to figure out why...perhaps someone else can tell me!!!

2. Make sure you put the correct language in your snippet code. If you call it XML but it's really C# (spelled csharp in snippet terms) you won't see it appear in your C# snippets after all...another ghost I chased...for a short while.

Sample snippet...for your time...more to come :)

<?xml version="1.0" encoding="utf-8" ?>
<CodeSnippet Format="1.0.0" xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
<Header>
<Title>system.serviceModel.diagnostics</Title>
<Author>Michele Leroux Bustamante</Author>
<Shortcut>serviceModel.diagnostics</Shortcut>
<Description>Sample system.serviceModel.diagnostics section.</Description>
<SnippetTypes>
<SnippetType>Expansion</SnippetType>
</SnippetTypes>
</Header>
<Snippet>
<Declarations>
<Literal>
<ID>perfCounters</ID>
<Default>true</Default>
<ToolTip>Enable performance counters: true|false</ToolTip>
</Literal>
<Literal>
<ID>wmiProvider</ID>
<Default>true</Default>
<ToolTip>Enable WMI provider: true|false</ToolTip>
</Literal>
<Literal>
<ID>logEntire</ID>
<Default>false</Default>
<ToolTip>Log entire message content (beware! production performance hit): true|false</ToolTip>
</Literal>
<Literal>
<ID>logMalformed</ID>
<Default>true</Default>
<ToolTip>Log malformed messages (or, provide your own logging mechanism, don't do both!): true|false</ToolTip>
</Literal>
<Literal>
<ID>logServiceLevel</ID>
<Default>false</Default>
<ToolTip>Log messages at service level: true|false</ToolTip>
</Literal>
<Literal>
<ID>logTransportLevel</ID>
<Default>true</Default>
<ToolTip>Log messages at transport level: true|false</ToolTip>
</Literal>
<Literal>
<ID>maxLog</ID>
<Default>100000</Default>
<ToolTip>Maximum message log count (runs out fast, must backup the file!)</ToolTip>
</Literal>
</Declarations>
<Code Language="XML" Format="CData">
<![CDATA[ <diagnostics performanceCountersEnabled="$perfCounters$" wmiProviderEnabled="$wmiProvider$" >
         <messageLogging logEntireMessage="$logEntire$" logMalformedMessages="$logMalformed$" logMessagesAtServiceLevel="$logServiceLevel$" logMessagesAtTransportLevel="$logTransportLevel$" maxMessagesToLog="$maxLog$" />
     </diagnostics>]]>
</Code>
</Snippet>
</CodeSnippet>

 

2/1/2006 9:05 PM Indigo | Visual Studio  | Comments [13]  |  View reactions  |  Trackback
 Wednesday, September 28, 2005

If you weren't at the PDC, you can still get the latest WinFX bits, with the latest drop of WCF and WPF:

http://www.microsoft.com/downloads/details.aspx?familyid=ffd636f0-86e9-41e8-9e1c-100a4cc4888f&displaylang=en

Of course you need MSDN subscription to install the latest Visual Studio 2005 bits on top...but the RC1 candidate is available up there, so I recommend you use that...apparently it only runs with Beta 2, so you can't work with the latest and greatest 2005 bits today and get WinFX running.

Do this if you want to be able to run any code samples I post on Indigo...er...WCF WCF WCF WCF...

ADDING MORE INSTRUCTIONS

I found a great blog post explaining all the steps for PDC DVDs or downloaded bits here: http://www.longhornblogs.com/rrelyea/archive/2005/09/16/PDC2005Software.aspx

These are the download instructions from Rob Relyea's blog:

1. Operating System Required - Windows XP SP2 or Windows Vista 5219 (not Windows Vista beta1!)

2. WinFx CTP installation
This installs WinFX on the machine...end users will need this done.
WPF (fka "Avalon"), WCF (fka "Indigo"), and .NET Framework 2.0 all get installed with an integrated setup.

3. Visual Studio (Beta 2!!!)  (or you can also install Visual Basic Express  or VC# Express - just make sure it is "Beta 2"!)  Sorry, there is currently no build of WinFX that is compatible with RC or RTM builds of VS!
Once the install is done, make sure you do step 2 of the VS setup...install Help content - use it offline if you want it to work its best with WinFX SDK content to come later.

4. Windows WinFX SDK
This installs a ton of help content (samples, documentation) and some great tools (xamlpad, etc...)

5. VS Extensions for WinFx
This installs Project Templates and Item Templates for Visual Studio.

 

 

9/28/2005 2:47 AM Indigo | Visual Studio  | Comments [4]  |  View reactions  |  Trackback

Sometimes it is really helpful to have different ways to build things...like WCF services for example...I can approach it from many different starting points. If I know I am going to host my services as part of a Web site/application...I might start from a different path than if I was building a truly service-oriented application that may or may not be always exposing services over HTTP and/or through IIS.

So you can do any of the following to create a service:

 a)       Create a new Web site project using the Indigo Service template and selecting HTTP (creates an IIS virtual directory for you, that's great!)

b)       Create a new Web site project using the Indigo Service template and selecting File System (this creates a file-based Web site, no IIS virtual directory, hosted with Cassini Web server)

c)       Create a new Class Library project then add an Indigo Service template item to it (no virtual directory is created for you, and no .svc endpoint is created...because the idea here would be to host this service “wherever you like“)

d) Create a new Console Application project then add an Indigo Service template item to it (no virtual directory or .svc but you can add self-hosting code to this application, coupling the host and service in one)

Some observations:

Option a) is useful for testing IIS services because it quickly generates a project that and creates the appropriate IIS virtual directory.

Option b) is problematic for a few reasons. First because in general, Cassini testing does not yield the same results as IIS-hosted testing when we’re talking about anonymous vs. authenticated access. Second because it requires NTLM authentication by default, requiring extra steps to enable access to your services on the development machine (I'll make a separate post on this)…possibly settings that will leak into deployment configs for QA and production if not caught. Whenever possible I think we should develop in the environment we will deploy in.

Both a) and b) have another drawback, that the service interface now gets lumped into the deployment of the ASP.NET Web site (the project it belongs to). That means either deploying source (hopefully no one will really deploy source in ASP.NET 2.0...just because you can) or precompiling the site (so now the code for the service is lumped into the ASP.NET application DLLs and it must now be versioned with those DLLS). This tightly couples the service (which should be an agile component of a system) to the ASP.NET application it is exposed through. I recommend there NOT be a template for creating indigo services with Web sites for this reason…because it moves you away from a pure service-oriented design.

Option c) is best because it implies that the service interface is part of a component that can be distributed and used by either an ASP.NET site, or a self-hosting environment, but coupled to neither.

Option d) couples the service to the host, nice for demos, not practical in deployment.

Of course, we always want tools for testing, that will make us quickly productive, and for that reason I say perhaps we are missing a few things. If we can have templates for services exposed as part of Web sites ( a) and b) ), we should also have template for creating self-hosted console services ( d) ), or IIS hosted class libraries ( c) with a twist ). The last item there is what we are missing perhaps, just in productivity terms:

e) Create a new Class Library then add the template item for IIS Hosted Indigo Service. This would create the IIS vdir and give us the darned .svc file for our class library, maybe even set the Build directory to \bin instead of \bin\debug or \bin\release so it will work without editing that.

Of course e) goes against my initial argument -> to force developers to build services in a service-oriented and decoupled manner...which would mean get rid of all but c) and watch people scream. I think what we'll need instead is a) through d) (plus e) if I get my wish) and we'll need to educate people why real services should be designed with c) because you know that a million and one code samples are already flying out to the Web that don't do c).

I'll post some samples separately, I wanted to get my rant out first. That feels better.

9/28/2005 2:36 AM Indigo | Visual Studio  | Comments [8]  |  View reactions  |  Trackback

A long time ago Benjamin Mitchell told me about this tip...and I recently shared it with a few others...so I thought I'd post it for the entire world that reads my blog...

If you turn on word wrap (Tools->Options->Text Editor->All Languages, select Word Wrap and show glyphs), you shouldn't have to say things like this during your code presentations:

As you can see here...oh...wait...let me just scroll over a bit so you can see the rest of this statement...there...oh...wait...just a little further...there...ok, just a liiiiittle further...ok, can you remember all that? Good.

9/28/2005 1:53 AM Visual Studio  | Comments [10]  |  View reactions  |  Trackback
    ON THIS PAGE
    SEARCH
    CATEGORIES
    ARCHIVES
    BLOGROLL

Designed by NUKEATION STUDIOS