Microsoft Developer Evangelist
Development
Time for Dallas TechFest!
Jul 20th
We’re only 2 weeks away from the 3rd annual Dallas TechFest! The schedule is set, the bags are being packed and the speakers (including me!) are polishing up their talks. Dallas TechFest has something to offer everyone, regardless of your particular chosen (or favorite) programming Languages:
This year’s schedule features well-known and local speakers from across 6 different communities including .NET, Java, PHP, Adobe, ColdFusion, Apple and IT Pro. Registration is normally $50, but if you use the code “dotnet” you can get a $25 discount! Make sure you sign up today as space is filling up quickly!
As an added bonus, everyone will receive a lunch, free Wi-Fi and a bag full of goodies from all of our sponsors! I hope to see you there!
Upcoming WP7 Training
Jul 15th
Jump start your development of Windows Phone 7 applications by attending Windows Phone 7 JumpStart. This free virtual live class, comprised of four instructor-led 3 hour sessions, will guide you in developing applications for the Windows Phone 7 platform using Silverlight and XNA.
Course sessions:
- July 20 – 10am: Session One: Getting Started with Microsoft Windows Phone and Silverlight
- July 20 – 3pm: Session Two: Programming Game Applications with XNA
- July 22 – 10am: Session Three: Programming Applications with Silverlight
- July 22 – 3pm: Session Four: Review and Wrap Up
Download the Windows Phone Developer tools beta to get started creating Windows Phone 7 applications today. This download includes: Visual Studio 2010 Expression For Windows Phone beta; Windows Phone Emulator beta; Silverlight for Windows Phone beta; Expression Blend for Windows beta; and XNA Game Studio 4.0 beta.
Windows Phone 7 Beta Bits are LIVE!
Jul 12th
Go get them right now from http://developer.windowsphone.com or the Microsoft Windows Download site! There are LOTS AND LOTS of improvements in the Beta bits, so make sure you give them a try. Be prepared that there are also some breaking changes, but nothing that should take you very long to update. Also, for those of you without Expression Studio 4 installed, the Beta release also includes a copy of Expression Blend for Windows Phone 7 included in the installation.
One single download for one simple installation! Doesn’t get any better than this
Just make sure you uninstall your old tools before installing the new ones according to the installation instructions.
Microsoft PDC 2010
Jul 12th

It looks like PDC10 will have an interesting twist, compared to previous PDCs:
I also didn’t see anything about a schedule, so I don’t know if there will be pre-conference sessions this year. The site does say that the focus is going to be on “Cloud Services, Phone, Tools & Technologies, Internet Explorer and Gaming”. I’ll provide more information once I learn more about it. Make sure you keep an eye on http://microsoftpdc.com for more information as well!
XNA Game Development for Windows Phone 7
Jul 7th
XNA Game Development for Windows Phone 7
Thursday, July 15, 10-11 AM Pacific Time
http://bit.ly/cCAIL8
Join us and discover a developer overview of how to build games for Windows Phone 7 with Microsoft XNA Game Studio 4. Learn about the developer tools, the XNA Framework, and the resources available to build interactive, compelling, games with Windows Phone 7. In this webcast you will learn how to create games for Windows Phone 7 using XNA Game Studio 4. This session will cover the programming model, how to work with content, game input, and available resources.
This webcast is hosted by the AT&T Developer Program. All actual attendees can enter to win an AT&T Smartphone. Winner will be notified via email after the Webcast.
Microsoft Announces WebMatrix Beta
Jul 6th

Released in beta form today, Microsoft WebMatrix provides everything a developer needs to get started developing web applications on the Microsoft technology stack. Included in the package are a development web server called IIS Developer Express, SQL Server Compact for easily building databases that support your website, and a rich publishing tool that allows you to easily get your applications published to the web.
WebMatrix also include support for the new Razor inline markup syntax. Intended to simplify your development, Razor requires much fewer keystrokes than ASP.NET and is well suited for inline markup. Here’s a short example of Razor to whet your appetite:
@{
var db = Database.OpenFile("SmallBakery.sdf");
var selectQueryString = "SELECT * FROM Products ORDER BY Name";
}
<table>
@foreach (var row in db.Query(selectQueryString)) {
<tr>
<td>@row.Id</td>
<td>@row.Name</td>
<td>@row.Description</td>
<td>@row.Price</td>
</tr>
}
</table>
All of this, plus an outstanding Application Gallery, is available TODAY in Beta form. Jump over right now to http://www.microsoft.com/web/webmatrix/ and get your copy today! I would also recommend that you download the WebMatrix PDF Book to help you learn the Razor syntax – pretty good introduction and it’s free to download!
Upcoming Community Events
Jul 5th
It’s been a while since I made one of these posts, so I figured I’d put one out there. I really need to do this every week like I used to. Except for the typical upcoming user group meetings that you can learn about from http://www.southcentralcommunity.com, here are a list of the community-oriented conferences
NWA TechFest 2010
Thursday, July 08, 2010 8:00 AM, Rogers, AR
First annual NWA TechFest! I’m presenting 2 sessions at the event: Developing Windows Phone 7 Applications with Silverlight and an Introduction to SketchFlow. There are a lot of great speakers there, including several of my co-workers and a whole gaggle of MVPs so make sure you attend. Besides – it’s free!
[ Event Details | Map & Directions | Add To Calendar ]
Dallas TechFest
Friday, July 30, 2010 8:00 AM, Richardson, TX
Dallas TechFest is back and will be occuring at the University of Texas at Dallas this year! Look forward to another day of phenomenal education by some of the best speakers from around. As in years past we will be having sessions on a wide variety of technologies including Microsoft .NET, Java, ColdFusion, Flex and PHP. Your conference ticket will include access to all general sessions, Lunch & Snacks throughout the day and an attendee bag with information and software from our sponsors. What Sessions are available you ask? http://www.DallasTechFest.com has all the details!
[ Event Details | Map & Directions | Add To Calendar ]
SQL (.Net) Saturday #28 Baton Rouge LA
Friday, August 13, 2010 12:00 AM, Baton Rouge, LA
Free SQL Server and .Net training! Chance to win great prizes! What more could a SQL Server Professional ask for? If this sounds good to you then don’t miss your opportunity to attend SQL Saturday! #28, the largest FREE training event dedicated exclusively to SQL Server, .Net, Development and Business Intelligence to hit Baton Rouge.
[ Event Details | Map & Directions | Add To Calendar ]
OpenCa.mp
Friday, August 27, 2010 6:00 PM, Addison, TX
OpenCamp is the SouthWest’s first multi-platform web conference. With top speakers covering topics ranging from social media to technical development, content creation, revenue generation and more, webmasters and web developers, bloggers, podcasters and technologists on any platform are welcome.
[ Event Details | Map & Directions | Add To Calendar ]
MVVM Light Messaging
Jul 5th
Since I started using the MVVM Light toolkit, I’ve gotten lots of questions about the it. In this post, I’m going to show you the basics of using the Messaging infrastructure. In the sample application attached, we have the situation where a Master page with a list of data items is trying to move to the Details page to show the details for one specific item. There are a couple of ways to do this, but the one I’ve starting using is the Messaging infrastructure in MVVM Light. It involves the ViewModels communicating with each other via a lightly-coupled messaging bus rather than a direct coupling or using the query string. Let’s break it down…
The sample application displays a fixed set of data elements in a list on the main page. When an item is selected from the list, it navigates to the details page and shows the details. Presuming you already have the main page working, here’s what’s left:
Step 1 – Send the message out to the bus
When you create a new ViewModel property using the MVVM Light snippets, the sample code that gets created asks you to make a decision between publishing the PropertyChanged event to the message bus or not. In our case, we want to publish to the message bus. This will allow registered receivers to pick up this message. So – inside the MainViewModel, we have this property:
public Person SelectedItem
{
get
{
return _selectedItem;
}
set
{
if (_selectedItem == value)
{
return;
}
var oldValue = _selectedItem;
_selectedItem = value;
// Update bindings and broadcast change using GalaSoft.MvvmLight.Messenging
RaisePropertyChanged(SelectedItemPropertyName, oldValue, value, true);
}
}
The RaisePropertyChanged method includes two overrides – this one publishes to the Messaging infrastructure for us. Now all we need is a listener…
Step 2 – Register the Details view model to listen for the appropriate message
Now that the message is getting published to the message bus, we need a receiver to pick it up and act on it. In our case, that’s the DetailsViewModel. In the constructor for the ViewModel, we add the necessary code to register for receiving SelectedItem PropertyChanged messages like this:
public DetailsViewModel()
{
Messenger.Default.Register<PropertyChangedMessage<Person>>(
this,
(action) => DispatcherHelper.CheckBeginInvokeOnUI( () => this.Item = action.NewValue )
);
}
Notice the Register statement – we need to register for instances of the PropertyChangedMessage message that transport Person objects. Our example is simple, so any type a PropertyChanged message is sent into the bus with a Person attached to it, the DetailsViewModel will pick it up. If there is any disambiguation that needs to be made, there are a couple of other overrides to the Register method that allow you to provide a “token” (i.e. message name) as well as a switch to manage whether or not derived messages will also be picked up,
Since the GlobalViewModel locator creates and manages the lifetimes of our ViewModels, the DetailsViewModel is always instantiated and is available at the beginning of the application lifecycle to register for these messages. When the messages arrive, even if we don’t navigate to the Details page, the DetailsViewModel is ready for us.
The full sample can be downloaded right here.
Adding MVVM Light Toolkit to an Existing Project
Jul 2nd
I’ve been meaning to write this up for a while, but seeing a question on Stack Overflow tonight prompted me to do it tonight, so here goes.
It’s relatively simple to add MVVM Light to an existing project. I’m going to use Silverlight as a sample, but you can do the same thing for WPF or Windows Phone. Presuming you’ve followed Laurent’s instructions on how to install MVVM Light onto your computer, the remaining steps are pretty straightforward:
- Add references to the MVVM Light Toolkit assemblies
- Create a folder in your project called ViewModels
- Create a ViewModelLocator class to serve as a repository for your ViewModels
- Wire up the ViewModelLocator into the App.xaml
After that point, it’s just like adding new views and new view models to your project. The harder part would be converting an existing “page” to behave more like a “view” and moving all the data collection code out into a ViewModel, but I’ll save that for a future post.
Here are some details for each of these steps if you’re interested…
Step 1 – Add MVVM Light References
There are 3 assemblies in the MVVM Light Toolkit – separate sets of DLLs for each platform. I’m using Silverlight 4, so these are the ones I need:
Step 2 – Create a ViewModels Folder
I use the folder structure similar to what the MVVM Light project template uses to keep my ViewModel code all together. This isn’t strictly necessary, but it’s good practice to do so.
Step 3 – Create the ViewModelLocator
This is the real key to the whole thing. The ViewModelLocator serves as a global repository of ViewModels. It manages their lifetimes, and serves them up when requested by the individual Views in the data binding process.
- Right-click on the ViewModels folder and choose “Add New Item…”
- Under the “Mvvm” tab, choose “MvvmViewModelLocator”. I usually name mine GlobalViewModelLocator, but you can name it whatever you want.
Step 4 – Wire up the ViewModelLocator
After the class is created, and is opened in the editor, check out the comments at the top. They provide the code you need to wire up the ViewModelLocator into your App.xaml as well as the code you need to wire up each individual ViewModel to its associated view.
- Copy the XAML for the part indicated to go into your App.xaml
- Open the App.xaml and past it into the Resources section
It might look like there is an error because of the squiggly blue lines, but that’s only because we haven’t compiled the GlobalViewModelLocator yet. Build the project now and the squigglies should go away.
The rest of the process is just like if you’d started out with an MVVM Light project. Create new ViewModel classes as necessary and wire them into both the GlobalViewModelLocator class and the View.
Open Source Databases for WP7
Jun 30th
One of the most frequent questions I get about the WP7 platform is “when are we going to get local database support?” Thanks to the heroic efforts of the Open Source community, there are now several alternatives for local database support on WP7:
- Windows Phone 7 database
http://winphone7db.codeplex.com/
Hosted on CodePlex, this project implements a Isolated Storage (IsolatedStorage) based database for Windows Phone 7. The database consists of table objects, each one supporting any number of columns. - Perst Embedded Database For Microsoft Windows Phone 7
http://www.mcobject.com/perst_eval
Perst is an open source / dual license embedded database for .NET and .NET Compact Framework. Andy Wigley, an APPA Mundi principal and Microsoft MVP, wrote a blog post outlining some of the changes he made to the open source database which have now been incorporated back into the mainline build at McObject. - db4o Open Source Object Database
http://developer.db4o.com/
db4o is an object-based database (as opposed to a relational database) designed for use in Silverlight and .NET applications. Since there is Silverlight 3 support, it *should* work on WP7. I’ve downloaded it and proved that it will launch a WP7 app with the db40 DLLs referenced, but haven’t tried really exercising the toolset yet. I’ll update the post when I have more data to share. - siaqodb Open Source Object Database
http://siaqodb.com/
siaqodb is an object database engine that currently runs on .NET 3.5+, Mono 2.4+, Silverlight 3 and 4 as well as WP7. It’s database management application allows you to use LINQ to run ad-hoc queries against the database, which is kind of a cool and unique feature.
It looks like I’m going to have to do a WP7 Database Smackdown at some point and share the results with you.









