Wednesday, April 30, 2008

Upcoming Microsoft Products

A few Microsoft projects currently being developed or already in some level of public testing make me fairly excited and I want to share them with you:

Microsoft Research: World Wide Telescope

worldwidetelescope

Imagine exploring the sky from your computer. Imagine an ever expanding collection of images from telescopes from all over the world and beyond streamed to your machine with seamless zooming and panning.

World Wide Telescope is an amazing application that will change the way astronomers work, teachers teach and consumers experience space and other worlds. Make sure to check it out:

Live Mesh

image

Instead of trying to hype up this (amazing!!) new platform and consumer application experience ill leave it to the experts and give you the main bullet points posted by Amit Mital, the General Manager for the project:

  • "Unified Device Management" - enabling your devices to report into a common service, for status, for health, or to report their location.
  • "Unified Data Management"- or the transparent synchronization of files, folders, documents & media, the bi-directional synchronization of arbitrary feeds, of all kinds, across your devices and the web.
  • "Unified Application Management" - for centralized web-based deployment of apps across the devices you own.
  • "Centralized Management" - where you could configure and personalize your devices and remote control into them from just about anywhere.
  • If this does not make you excited then don’t worry about this technology, otherwise read on at the links below!

    image

    Microsoft Research: HD View (Beta)

    HDView_Logo_Sml

    HD View is yet another image technology from Microsoft but with an interesting twist. Imagine taking hundreds of photos at various zoom levels and resolutions of an area and being able to automatically stitch them together into a panoramic and zoomable image. This is exactly the experience that HD View brings and really opens up photography to new rich experiences.

    hd_viewChief 

    Sunday, April 27, 2008

    GTA IV: Video Preview

    Even if you are not a fan of the Grand Theft Auto series I highly recommend checking out this video trailer. It is truly the most amazing graphical representations of my home town (NYC) I have ever seen: http://www.gametrailers.com/player/33327.html

    Warning: Some mature content in the video preview

    Thursday, April 24, 2008

    Away at Training

    Sorry for the lack of posts but currently I am at Microsoft training over in Redmond. The Microsoft campus is amazing and Washington State is very different then what I am used to being a “hardcore” New Yorker. I will post more later but here are some pictures from the flight in:

    img025img021 img012

    Saturday, April 19, 2008

    Super Crunchers – Audio Book Review

    supercrunchersI have recently started listening to Audio books as another way to enjoy books while on the go. My service of choice at the moment is Audible.com which has descent prices and a good selection.

    After some consideration I have decided to make my first book choice: Super Crunchers by Ian Ayres, narrowed by Michael Kramer.

    If you never heard of this book before, here is a summary by the publisher:

    Why would a casino try and stop you from losing? How can a mathematical formula find your future spouse? Would you know if a statistical analysis blackballed you from a job you wanted?

    Today, number crunching affects your life in ways you might never imagine. In this lively and groundbreaking new audiobook, economist Ian Ayres shows how today's best and brightest organizations are analyzing massive databases at lightening speed to provide greater insights into human behavior. They are the Super Crunchers. From Internet sites like Google and Amazon that know your tastes better than you do, to a physician's diagnosis and your child's education, to boardrooms and government agencies, this new breed of decision-maker is calling the shots. And they are delivering staggeringly accurate results. How can a football coach evaluate a player without ever seeing him play? Want to know whether the price of an airline ticket will go up or down before you buy? How can a formula out-predict wine experts in determining the best vintages? Super crunchers have the answers.

    In this brave new world of equation versus expertise, Ayres shows us the benefits and risks, who loses and who wins, and how super crunching can be used to help, not manipulate, us. Gone are the days of solely relying on intuition to make decisions. No businessperson, consumer, or student who wants to stay ahead of the curve should make another keystroke without listening to Super Crunchers.

    Now that I am almost done with the book I feel I can fairly review it and its a positive review. The book is very interesting and the narration is excellent! I really cant stress how much Michael Kramer brings a relative passive topic alive and keeps you glued to the story.

    This website is not about book reviews so I wont bore you with any additional details, but if you like audio books or ever wanted to try and listen to one this is a great one to get.

    Note: If you have never been a customer of Audible you can get one free audio book by using the special offer link available to TWiT listens, here it is.

    Friday, April 18, 2008

    Expression Blend 2.5 March 2008 Preview Tips

    Using Expression Blend 2.5 from the March preview release for a few weeks now I have learned a handful of tricks/features that are not life-changing but definitely useful to know or at least notice. Here is my list:

    Changing Options

    Changing Options

    The tips in this section can be accessed by going into the Tools > Options Menu

    image

    Default Document View

    The default Expression Blend document window view is "Design View". I for one like the Split view much better and prefer it as the default option. Using the Document settings tab you can configure the default selection for opened windows making it less annoying having to switch each time.

    image

    Changing UI Theme

    By default a very dark theme is used in Blend but an additional option is built in that can lighten things up.

    Under the Workspace menu the Theme selector lets you choose between the Dark or Light theme.

    image

    As you can see in the screenshots below the difference is subtle but I find the Light Theme much more pleasant on the eyes.

    Dark Theme Light Theme
    image image

    Toolbar

    Asset Library

    The Asset Library button (arrow-like button in the toolbar) can be a little confusing to use at first when your not used to its display view.

    image

    In these screenshots tabs like System Controls, Media or Custom Controls almost look like explorer column filters but they are actually Tabs.

    image

    As an example the Custom Controls are located under the Custom Controls tabs so use these tabs as filters to find the right controls or items you want to drag into the design surface.

    Properties & Events

    Properties Search

    I really have to give the creator of Expression Blend credit here. This is a small feature but makes a big productivity boost (and I hope its implemented into VS 2008 service packs or future versions)

    image

    Using the Search box you can filter down your proprieties to the exact item your looking for, this is very helpful and wont require you to search open/close various sections just to find what you need.

    image

    In the example above I use the word "Font" to filter down all the Font related properties. Works great!

    Creating Events

    Since Expression Blends works on top of a Visual Studio projects controls have the concept of events and their names can be assigned directly from Blend interface.

    To get into this menu go to the properties window and click on the icon with a yellow thunderbolt as shown below on the right.

    image

    In the above screenshot if I typed in the name TextBoxControl_GotFocus (or any other name) into the GotFocus field it would add the appropriate code-behind event placeholder.

    Note: If you did not create a code-behind file for your XAML page this wont work and result in an error.

    Thursday, April 17, 2008

    Silverlight 2, Beta 1 - Setting up Local Help Resource

    Today I learned a trick on how to configure the local help documentation for Silverlight 2.0 Beta 1. Here are the instructions:

    Instructions

    Prerequisites

    You should already have installed the development tools for VS 2008 / Silverlight Beta 1. If you have not, see my getting started post.

    Step #1: Download the complete help file

    http://go.microsoft.com/fwlink/?LinkId=111131

    Step #2: Place help file into correct folder

    Navigate to the “C:\Program Files\Microsoft SDKs\Silverlight\v2.0\Documentation\Help” folder. You will notice that “SilverlightDocumentation.chm” is only a dummy file.

    To correct this place an extracted version of the newly downloaded help file from step #1 into this folder.

    Step #3: Configure VS 2008 to use the new help file

    Follow these steps to configure Visual Studio 2008:

    • Open Visual Studio 2008 as an administrator.
    • In the Help menu, choose Index.
      • Microsoft Document Explorer displays.
    • In the “Filtered by”: drop-down, choose (unfiltered).
    • In the Look for field, type “Collection Manager”.
    • Below the Collection Manager heading, double click Help.
    • Below the “Collections available for inclusion in VSCC” heading, check “Microsoft Silverlight 2 SDK Documentation”.
    • Click “Update VSCC”

    Conclusion

    Your local help should now work as expected.

    Credit: I learned this trick by reading the manual for a hands-on lab posted in this blog entry.

    Silverlight 2 - Excellent Demo Links

    While Silverlight.net has some excellent and constantly growing set of links for sites that use Silverlight a few standout to me and I wanted to share them in the list below:

    Working Applications

    Demo Applications

    Specific: DeepZoom demos

    Note: Some links above use SL2 Beta 1 and therefore require this beta runtime

    Useful Presentation Tools

    When presenting we all face many challenges but some of them can be negated by great tools. Yesterday I was asked about one such tool and decided to not just send one link but put together a summery of a few such tools.

    Presentation Tools

    Tool Description
    ZoomIt This utility allows you to zoom to a particular part of the screen through a simple keyboard short-cut (ctrl-1) and back to normal view by pressing ESC.

    You can also highlight an area with a red marker by clicking the left-mouse button while zoomed in.

    This free tool has other good features and is definitely worth the small download.
    SharedView Beta2

    sharedview
    While doing demos or presenting in person is always great its simply not always possible.

    SharedView is a great (and free) tool that allows you to setup a meeting with up to 15 people to share your screen. Other tools exist but this one is free and works well.

    The one downside of Beta2 is there is no support yet for voice-chat so a separate phone conference will still be required.
    Snippet Manager

    snippet manager
    One of the challenges of presenting a code-centric demo is speaking and writing code at the same time. Few have mastered this technique and the rest of us need something to help make this process easier.

    One such tool (written by Karen Corby) helps manage this process by allowing you to create a pre-configured snippet library that can be easily dragged into a presentation to give you the benefit of showing code as it "comes together" without having to write it while speaking.
    Camtasia

    camtasia box
    A pre-recorded video can be a lifesaver during presentations. Complex tasks on the screen recorded once can then be shared as many times as necessary without mistakes.

    While other products exit Camtasia studio is worth every penny and is arguably the best in the market.

    (Price: $299.00 but worth every penny)

    Monday, April 14, 2008

    Creating a quick sample IIS hosted WCF Service

    Today I came across an MSDN article that describes how to create a sample IIS hosted WCF Service. The steps outline were manually and unnecessary if you have access to Visual Studio 2008 so here is a quick guide on creating your first sample IIS hosted service using a VS 2008 project template.

    Creating the Sample

    First open up Visual Studio 2008 and go into Create New Project.

    image

    Navigate to the Web portion of the Project Types tree in the language of your choice (C# in my example above) and select WCF Service Application from the Templates side.

    image

    Create your sample service and you will get a project that should look like the screenshot below with a Contract interface (IService1.cs) and Service1.svc file to represent the actual service endpoint.

    image

    Congratulations you now have a sample (or starting point) WCF Service that is hosted by IIS.

    Moving to the real IIS

    As a final note I want to remind everyone that by following these steps you now have a WCF Service that is hosted by the Visual Studio Development Server (by default).

    I recommend switching to IIS Web Server in the project properties tab if you have it available on your machine as that will give you a more realistic hosting experience (which the Development Server is not)

    image

    Using your CustomControl in Silverlight 2 Beta1

    So you've done it, you created a brand new empty project, and now your ready to try some things out in SL2. You add a few random controls, it could be an Image control, or maybe a few TextBox controls.

    After 10-15 minutes you've probably got the basics working, and now you're ready to do something more advanced, like lets say create a Custom Control (CustomControl tag) and place it on the default main page (Page.xaml).

    Creating a UserControl

    To start you are going to do what your used to, you will right-click on the project, you'll select add, then New Item.

    image

    In the next screen you'll add a Silverlight User Control and name it whatever you want.

    image

    As a final step you'll add some text (or some other controls) to add a visual element to your new custom control, and move back to Page.xaml to start using it.

    Problem... where is my control?

    And so the frustration will begin (unless your smarter then me). You will not find any way to reference your newly created control, oh the pain.

    Sure, MSDN has a reference on this subject, and there is even mention of a custom control in the excellent ScottGu Digg Sample, but if you are anything like me, you are still lost.

    Solution

    The solution is actually ever simple once you "Get it", so here is a simple explanation:

    You need to add your own projects namespace to your Page.xaml file before you can use UserControls from your own project and start using them.

    image

    In my case the custom control was named PopupSection (hence PopupSectoin.xaml in the screenshot above), but I could not get my code to use it until I did this:

    image

    As you can see on the 4th line in the screenshot above I implement a reference to my namespace by using xmlns tag reference, that configures uc (it can be named anything you want, I just like the name uc) to reference the namespace of my project, that happens to be SilverlightInterfaceDemo (same as the name under x:class="...)

    So now like magic intellisense has my control listed when I type in the following code anywhere inside of the Page.xaml XAML:image

    (In the code above I reference my new control using the uc:PopUpSectoin name, and can then start setting properties on it like the Name property shown above.)

    Bad Assumptions

    What I still don't "get" is why Page.XAML does not automatically contain reference to "UserControls" inside of the project. My understanding of the full SL2 architecture is still growing so more on this later.

    Conclusion

    Silverlight 2 is an amazing technology once you get beyond the learning curve of the basics and I hope this post helps at least one person in the future to start using User Controls. As always if anything in this post is wrong or can be done easier, don't hesitate to contact me or post a comment.

    • Additional Learning: Hands-on labs that cover UserControls and Blend 2.5

    Friday, April 11, 2008

    Silverlight: Image tag not working

    If you are using Silverlight 2.0 Beta 1 and are trying to simply display an image that is a resource in your project, in lets say the Resources resource folder it seems like a simple task. Unfortunately Silverlight wont tell you if you make the most basic mistake in this beta version.

    image

    In the example above you must reference the image in the resource folder by using a forward slash in the XAML Source property of your <image> tag, not a backslash! Use the backlash and nothing will display.

    Its a simple, armature mistake but it can cost you a lot of time. Here is the proper syntaxes example:

    image

    I am sure in the future this will get easier and provide more information for such simple mistakes.

    Silverlight 2.0 Beta 1 Error - Creating a new project

    Silverlight 2.0 Beta 1 - Error

    clip_image002

    Error: You need to install the 2.0 versions of the Silverlight runtime and the Silverlight SDK before creating a Silverlight project.

    Reproducing Error

    image

    To cause this error to happen I simply tried to create a new Silverlight 2.0 Beta 1 Application Project. (Library project did not cause error)

    Odd Note and Workaround

    One odd thing is that existing projects on my computer (like the digg sample) opened and ran in debug without issue. This is actually a potential work around if the resolution below does not help you. Simply use another computer to create your project and use your machine to develop it by opening the pre-made project.

    Resolution

    To resolve the errors I had to take the following steps:

    1. Restart my PC to make sure nothing was locked in memory
    2. Uninstalled all installed Silverlight components (Tools, Runtime, SDK, Hot-Fixes from Chainer, etc)
    3. Manually removed all Silverlight files and registry keys that were not cleaned up for some reason by the uninstall step above
    4. Uninstalled 3 different versions of Blend Beta/Alpha versions
    5. Opened Visual Studio 2008, verified no Silverlight project exists and that dig sample does not open
    6. Reinstalled all tools directly from the getting started site:
      1. http://silverlight.net/GetStarted/ (Tools Install Chainer and runtime for Beta 1)

    Honestly the list of fixes above is fairly "wide" but I am not sure what helped me resolve the issue.

    Thursday, April 10, 2008

    TFS Error: Object Reference not set to an instance of an object

    image

    Today while working with Team Foundation Server 2008 on a Virtual PC 2007 instance I started getting the error above:

    Team Foundation Error

    Object reference not set to an instant of an object.

    Restarting the virtual machine got ride of the error and some people I talked to reported seeing this before specifically on VPC or when memory starts running low. I don't know what my problem was but memory might have been an issue.

    (The image I was using is publicly available on this link)

    Home Media Center PC - Top 5 Tips, Things you did not know

    A few weeks ago my buddy Steven Lindsay put together a video called Top 5 things you didn't know you could do with your Windows Vista Media Center PC. The vide is excellent, short and to the point. This is definitely worth watching if you have a Media Center PC, so check it out.

    Tips List:

    • Setting up recordings on items not yet listed in the TV Guide
    • Internet TV
    • Sports Tips: Live Sport Scores and more
    • Using Windows Home Server as a Media Server
    • Media Center Extenders (Addition displays around the house)

    Wednesday, April 9, 2008

    Windows Vista Aero... Missing?

    I recently got my first computer running Windows Vista Ultimate as its primary operating system. I was happy to finally get into Vista as the Windows XP experience is obviously lacking many of the excellent usability and user experience improvements now available in Vista Ultimate.

    Using Vista I was immediately in love with features such as Search in the start button, nicer icons, and improved networking screens.

    image

    image

    image

    Aero

    The one big thing I could not find though was something called Aero. Aero was supposed to be a major interface improvement with transparent windows, 3D alt-tab, glass-like features, and other UI improvements (see some screenshots below)

    expwinvista_aero_img02 expwinvista_aero_img03 expwinvista_aero_img04

    Finding Aero

    Doing some digging in settings I figured out why I did not see Aero, it was turned off.

    Turning On Aero

    If you have the same problem here is how you solve it:

    1. Go into Control Panel > Personalization

    image 

    2. Next go into Window Color and Appearance

    image

    3. Then click on "Open classic appearance properties for more color options" link

    image

    4. In the Appearance Settings screen you should see a Color Schema selection. In the screenshot below you will see it set to "Windows Vista Basic" and that was my problem.

    Switching this to "Windows Aero" and hitting OK solved my problem and enabled all the very nice User Experience features.

    image

    Note: From what I've heard limited hardware on a machine could make Aero unavailable. I don't have all the details but I am sure you can find them by doing some Internet Searches.

    Remote Desktop is your friend

    Lets say you have a scenario where you are on a VPC (Virtual Machine) and are logged in as an Administrator. You now configure something on that machine that needs to be tested as a more limited user.

    To meet your testing requirements you decided to create a special local account on the VM which is restricted enough to simulate correctly for your scenario, So now what? how do you start testing?

    One option is to log-off the VM and log back in as the new restricted user account.  But what if you log-in and find that you need to make more changes as Admin to get your scenario to work, what now? Its simple, you will be in logon/logoff hell.

    Remote Desktop

    Yesterday I learned a trick to make life much easier in just such scenario: Use Remote Desktop.

    Since Windows will allow one Remote and one Console user to be logged in at the same time this works great. In my scenario above id simply stay logged in as Admin to the console of my VM using Virtual PC 2007 interface and then RDP into the box as the more limited user to test anything I needed.

    (Thanks Brian for this tip!)

    One additional note: If you cannot connect to your VM from the host machine don't forget you can even Remote Desktop into the Virtual Machine from inside the Virtual Machine itself. Just remember, turn of "Connect to console" since you will already have one such connection and it will fail.

    With every such new trick learned we become empowered to work faster and better.

    Tuesday, April 8, 2008

    Visual Studio Team System - Branching and Merging

    Since the 2005 edition Visual Studio Team System (VSTS)  has supported complex Branching and Merging scenarios that facilitate parallel development of various kinds.

    While VSTS makes the basics behind this process fairly simple using a rich GUI interface (or command-line of you prefer) the topic itself is complex involving many patterns and scenarios. To help people understand the proper ways to leverage this functionality various resources exists and some of them are below for your reference:

    The Basics

    Before learning the complex activities behind Branching and Merging you must understand Source Control in VSTS.

    Branching and Merging

    Branching and Merging Videos

    Monday, April 7, 2008

    Domain Trust-test

    Today I heard a very interesting approach to help you test potential Domain/User trust issues. Such issues can arise due to the configuration of cross-domain trusts and/or other configuration settings in your environment.

    Problem

    Lets say you have a scenario were you are setting up a server that will require users to connect to it (or one of its services) with their domain credentials, but your not sure if those domains can speak to the domain were your server is attached.

    Solution

    The solution I heard is to simply use the Windows Explorer application on the machine in question and try to give a user per domain read-rights on some miscellaneous text file. If the users from one or more of the domains your checking cannot be found in the list if available users then you probably have an issues.

    This makes a lot of sense since the way Explorers file-permission screens work is the same way other AD-domain applications work, by querying the AD for user information. If the user is not in the list, the domain most likely cannot be queried or some other issues exists.

    Conclusion

    This approach might be obvious to IT Pro's but to me as a Software Engineer tricks like this can be a life saver when I am forced to cross into a different role for a particular project or situation.

    If a better approach exists or if my solution is wrong please do let me know by email or by posting a reply to this entry.

    Visual Studio Codenames

    Today I was listening to a Microsoft internal presentation and they kept referring to codenames of our Visual Studio products. This aspect of the presentation was not secret by any means as all of these names are very much public knowledge, but my big issue is they were confusing me.

    You see life outside of Microsoft tends to refer to products in their finished state: Visual Studio 2005, Visual Studio 2008, etc. (This might not be true everywhere, but has been true for me.)Now though that I work for the company of acronyms and codenames I am starting to pay more attention to them in an attempt to stay sane.

    To help, here is one collection of codenames everyone should probably know (and im sure has heard of) in the VS.NET family:

    Codename Description
    Everett Visual Studio 2003
    Whidbey

    Visual Studio 2005

    Orcas Visual Studio 2008
    Rosario Visual Studio Team System 2008+ (source)
    Hawaii "Visual Studio family past Orcas" (source)

    If anyone has additional names that belong to this list and I missed please dont hesitate to contact me with them or post a reply to this entry.

    Thursday, April 3, 2008

    Goodbye Google Ads

    Now that I work for Microsoft I no longer feel good about having Google Ads on my personal blogs. Don't get me wrong I am not trying to bash Google in anyway, instead realistically this is not a significant source of income for me and to help the competition at this personal level without even having a good cause behind it seems silly.

    <adds removed from blog>

    I still though like the idea of having ads on my websites and therefore am looking for other options. My first thought was to see if Microsoft had a similar program to place Microsoft ads on my website but was surprised to find no such thing. I am puzzled on why this does not exist... but that's reality.

    I did though find three affiliate style programs being offered by the Microsoft Affiliates website microsoftaffiliates.net (beta programs). These programs offer money for adcenter sign-up referrals, Live OneCare trial downloads and even Live Toolbar installs. This does look interesting and I will pursue it.

    Wednesday, April 2, 2008

    Silverlight 2.0: Additional Tool Links

    The other day I posted an entry titled Silverlight 2.0 - Get Started with some descent links to get people going. Since then though my tool-chest has expanded to include two additional resources:

    Deep Zoom Composer

    We are pleased to present a technology preview of Deep Zoom Composer, a tool to allow the preparation of images for use with the Deep Zoom feature currently being previewed in Silverlight 2 Beta 1. The new Deep Zoom technology in Silverlight allows users to see images on the Web like they never have before. The smooth in-place zooming and panning that Deep Zoom allows is a true advancement and raises the bar on what image viewing should be. High resolution images need to be prepared for use with Deep Zoom and this tool allows the user to create Deep Zoom composition files that control the zooming experience and then export all the necessary files for deployment with Silverlight 2.

    Download: http://www.microsoft.com/downloads/details.aspx?familyid=457b17b7-52bf-4bda-87a3-fa8a4673f8bf&displaylang=en

    Training Resources:

    Microsoft Expression Blend 2.5 March 2008 Preview

    We are pleased to present our next preview of Microsoft® Expression Blend™. Use Expression Blend 2.5 to create and modify managed Silverlight 2-based applications. Expression Blend for Silverlight 2 includes all of the features in Expression Blend 2 but has not reached the quality level of Expression Blend 2 for WPF or Silverlight 1 development.

    Download: http://www.microsoft.com/downloads/details.aspx?FamilyId=32A3E916-E681-4955-BC9F-CFBA49273C7C&displaylang=en

    Conclusion

    Both tools are excellent to play with but do expect some bugs as these are very early releases.

    I plan to put together some demos using both tools here and will blog about it in the future. Its an exciting time to be a Microsoft developer!

    Can't read Compiled Help (.chm files) after Vista sp1

    The other day I installed Vista Service Pack 1 on my machine and had no real issues until today. While the problem I just had is not serious it is worth documenting.

    Opening CHM file

    Today I needed to read some parts of a CHM file I downloaded directly from MSDN and the content would not display, here is a screenshot:

    image

    The address is not valid

    The error in the sceenshot puzzled me, so I started to think what had changed as not too long ago this same CHM file opened for me just fine. I then realized I had installed SP1 since then and perhaps something had changed.

    A quick search revealed a knowledge base article with the following suggestion that resolved the issue for me:

    Method 2

    1. Right-click the CHM file, and then click Properties.
    2. Click Unblock.
    3. Double-click the .chm file to open the file.

    My best theory is that Vista SP1 added this new "block/unblock" security enhancement for CHM files downloaded from untrusted sources such as the Internet.

    I hope this post helps save someone time in the future, good luck friends.

    Tuesday, April 1, 2008

    Dinner with Scott - Thank you to all

    I just wanted to say thank you to Scott Hanselman and everyone else who made it out tonight on short notice for dinner.

    While I cant speak for everybody I had a great time and it was a pleasure to interact with others who have the same passions for Microsoft technologies, something I don't get to do often out side of work (Yes, I've never even been to a user group meeting before.

    I hope everyone makes it home safe and lets do this again.