Feed Icon  

Contact

  • Bryant Likes
  • Send mail to the author(s) E-mail
  • twitter
  • View Bryant Likes's profile on LinkedIn
  • del.icio.us
Get Microsoft Silverlight
by clicking "Install Microsoft Silverlight" you accept the
Silverlight license agreement

Hosting By

Hot Topics

Tags

Open Source Projects

Archives

Ads

Reading Petzold's Applications = Code + Markup

Posted in WPF at Thursday, August 31, 2006 3:25 AM Pacific Daylight Time

After Tim Sneath posted that Petzold's WPF book was available I ordered it on Amazon and I received my copy yesterday. I'm only on chapter 2 of 31 and so far I like Petzold's approach of code first and markup later. At first I was skeptical thinking that you could teach ASP.Net via code first and markup later, but would you want to? However, I'm already seeing how this is helping me to understand the basics before I jump into pure xaml (which might also be helping in teaching ASP.Net). Karsten Januszewski is already on chapter 7 and his comments are encouraging:

I'm only to Chapter 7 of 31 chapters and I am riveted.  already have that feeling when reading a great novel when you don't want it to end.  It actually does read like a novel to me, with a narrative arch as it negotiates its methodical way through the WPF jungle of APIs. 

Only on chapter 7! I'd better get back to reading if I ever hope to finish and start writing code + markup. :)

Technorati Tags: WPF

Install Database Pro CTP5 w/o SQL Express

Posted in Sql and Xml at Wednesday, August 30, 2006 7:50 AM Pacific Daylight Time

As I mentioned in a prior post, VS Database Professional CTP5 requires you to install SQL Server Express as part of the setup. On my current project I just started to do some database work so I really wanted the CTP installed, but I didn't want to install SQL Server Express on my virtual machine since I already have a full blown SQL Server installation running. So with some help from Regmon I figured out what registry key the installer was looking for.

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\Instance Names\SQL]
"SQLEXPRESS"="MSSQL.1"

Now run the installer again and it should skip the SQL Express install. You will have to change some settings in Visual Studio under Options -> Database Tools -> Design-time Validation Database to be the correct SQL instance since you won't have express running. Also, you can delete the registry key once you get everything installed.

NOTE: Don't modify the registry if you don't know what you're doing. :)

You can download the registry file here.

Technorati Tags: SQL Server - Datadude - Development

Snooping WPF

Posted in WPF at Thursday, August 24, 2006 8:01 AM Pacific Daylight Time

Yesterday I was working on migrating the Coding4Fun FreeCell application to the July CTP as a simple task to better understand WPF styles and templates. As I was migrating the code I kept getting binding errors and, due to my ASP.Net background, I kept wishing for some sort of "View Source" type of option. Well today I came Snoop via John Grossman:

[Snoop] developed out of internal tools originally built into Expression that help us inspect our visual tree.  Originally we dumped the tree to a text file, then Pete put some UI on it, then Kenny incorporated the UI into Expression, and since then Pete has raised the stakes repeatedly making it standalone and adding features such as being able to inspect and even set values in the tree, and to be able to set breakpoints on data changes. 

This is a very cool little application that let's you walk through the objects in the visual tree. Not the just the visual tree you define in your xaml, but the visual tree that is generated after all the databinding and template binding have been done. Very nice and very useful.

Technorati Tags:

Is That a Runtime in Your Browser?

Posted in ASP.Net/Web Services | Avanade | .NET | WPF at Thursday, August 24, 2006 3:37 AM Pacific Daylight Time

In my life as a developer I have somehow never been on a project where I was creating a windows forms application (or a VB6 UI for that matter) AFAIR. Somehow I was always doing either ASP, ASP.NET, or some backend application with no real UI. My current project is different in that it is a smart client application. However, the client really wants to use WPF for the UI.

The more I understand WPF, the more I feel like I'm building a web application more than a forms application. The UI is all based on markup and you have databinding that seems very ASP.Net like. The line is blurred even more when you add in XBAPs which means you can run the WPF directly in the browser. However, WPF application development seems to blast past ASP.NET development at this point.

On my last project I built a really simple management UI using ASP.Net and Atlas. As much as Atlas tries to integrate AJAX into ASP.Net, I still felt like I was back in my ASP spaghetti code days. Kyle Huntley, a fellow Avanuat, makes a similar observation:

Atlas / Ajax does not represent any “Best Practices” in development from a purely technical standpoint; there are better ways to do it all. It is the unfortunate reality that the industry has been unable to settle on a single well-conceived runtime environment and has instead taken a drunkard’s walk to arrive at a very unappealing, but relatively standard, programming environment. Ajax is simply a way of trying to paper over the “poor” client characteristics of the browser / markup technology rootstock.

WPF can give you a richer experience than AJAX and without all the spaghetti mess. As another fellow Avanuat TSHAK says:

In the midst of all of the hype around the cool hacks that you can with a web browser, it is important not to ignore the innovation happening around application development on the Windows platform.

I definitely agree that WPF is taking us in the right direction and gives us a much cleaner development story than ASP.NET/Ajax. However, you might not have the option of assuming .NET 3.0 on the client for quite some time. But if you do have control over what is on the client, then WPF is a great choice for smart client applications (or is it a rich client?). Then you have the choice of running in the browser or not which gives you lots of great options.

So I personally think the runtime is the way to go, whether or not you run it in the browser. Now it is just a question of how well Microsoft drives WPF adoption and how Microsoft developers adapt to this new paradigm of client UI development.

Technorati Tags: - -

Extending Community Server

Posted in .NET at Tuesday, August 22, 2006 3:41 AM Pacific Daylight Time

I have to commend Telligent for how easy they made it to extend Community Server. I recently setup a new blog to use for posting videos of my son so that my brother-in-law who lives out of state can see him grow up (he asked me to). However, I wanted to use mp4 video files so that the videos could be viewed as podcasts or on the website. After some fiddling around I ended up writing a CSModule which simply adds the player html code to the post if you're viewing it from a browser while omitting it if you're using a feed reader. It was very easy to do this and because of that I plan on writing more in the future.

Technorati Tags: -

VS Database Professional CTP5

Posted in Sql and Xml at Monday, August 21, 2006 3:51 AM Pacific Daylight Time

The CTP5 is now available. I'm installing it right now and I already have a complaint.

<rant>
Why do you force me to install SQL Express when I already have SQL Developer installed!?!?!
</rant>

I don't want to install SQL Express, but it seems that datadute, along with ASP.Net, makes my life difficult without it. Is there some way to avoid the SQL Express installation? I thought we had already discussed this...

Update: I figured out a way around this and posted it here.

Technorati Tags: - -

WM5 Beta Exam Promo Code

Posted in Gadgets | Certifications | Windows Mobile at Monday, August 21, 2006 2:46 AM Pacific Daylight Time

Via Jason Langridge:

We've just released preliminary details of the Microsoft Windows Mobile 5.0 - Application Development certified professional exam.

This exam is currently in development. It is expected to be released in its beta version in August 2006. 

To get a headstart on studying for this you can review the pre-release information at:

http://www.microsoft.com/learning/exams/70-540.mspx

You can head over to the Vue website and register for this exam right now. The beta exam is exam number 71-540. You can schedule to take it anytime after September 5th, 2006.

The promo code for this exam is BTA540 which will allow you to take it for free!

Good luck!

Update: More information on the exam and the promo code here.

Technorati Tags: -

Clipboard Paste Live Writer Plugin

Posted in .NET | Live Writer at Thursday, August 17, 2006 11:55 AM Pacific Daylight Time

If you copy source as html (or have any html in the clipboard), hitting paste in Windows Live Writer pastes the text without the markup. So since there is an SDK and some great samples, I went ahead and wrote a simple plugin to paste the clipboard contents as html (in about 10 minutes).

public override DialogResult CreateContent(IWin32Window dialogOwner, ref string newContent)
        {
            DialogResult result = DialogResult.OK;
            if (Clipboard.ContainsText() == true)
            {
                newContent = Clipboard.GetText();
            }
            else
            {
                result = MessageBox.Show(dialogOwner, "Copy your HTML to the clipboard.", "Paste as Html", MessageBoxButtons.OKCancel);
                if (result == DialogResult.OK && Clipboard.ContainsText() == true)
                {
                    newContent = Clipboard.GetText();
                }
            }
 
            return result;
        }

I've applied to join the CodePlex project so maybe my humble contribution will get added, but for now you can download it here.

Technorati Tags: -

Technorati Tags in Live Writer

Posted in General | Live Writer at Thursday, August 17, 2006 10:56 AM Pacific Daylight Time

Via Greg:

Feeds.com - Write a Windows Live Writer plugin using C#

However I didn't want to sleep without writing a plugin and tried to write a more useful plugin to add Technorati tags to blog posts.  Here I write about the process I followed to let others start coding for Live Writer.  I created a workspace on CodePlex to write plugins for fun and share them with others.

Very cool! Although I think I discovered a bug with trying to put spaces into a tag. I think I'll writer a plugin to add source code (so you don't have to change to HTML view). 

Technorati Tags: -

Update: Testing out the WMP now playing. Note: if you want to use this you must install the Blogging Plug-in for Windows Media Player 9 Series. You can get the WMP live plug-in from the CodePlex workspace.

[ Currently Playing : High - James Blunt - Back To Bedlam (04:03) ]

Testing Copy Source as HTML

Posted in General | WPF at Thursday, August 17, 2006 10:04 AM Pacific Daylight Time

How well does this work with Live Writer? (got the CopySource settings from here)

    public partial class Window1 : Window
    {
 
        public Window1()
        {
            InitializeComponent();
            TopPanel.MouseLeftButtonDown += new MouseButtonEventHandler(TopPanel_MouseLeftButtonDown);
        }
 
        void TopPanel_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
        {
            DragMove();
        }
 
        public void CloseWindow(object sender, EventArgs e)
        {
            this.Close();
        }
    }

Just some sample WPF code that I'm playing with. Seems to work pretty well with Live Writer.

CS Paperclip Theme Modifications

Posted in General at Thursday, August 17, 2006 8:54 AM Pacific Daylight Time

I decided that I would like to change the top graphic on the paperclip theme which I'm using as a skin on my blog. However, there doesn't seem to be a source file for the graphic and the only reference to this that I found was on Dennis's blog here. Dennis not only modifies the graphic but changes the width of the theme as well (I'm fine with the smaller width).

Anyone else have a source file for the graphic? I modified it but I definately lost some of the crispness on the note.

Live Writer Ping Servers

Posted in General at Thursday, August 17, 2006 2:55 AM Pacific Daylight Time

Via Greg:

OK, AQ - Ping Weblog Servers

"...Here is a list of ping servers to cut and paste into the form located in Tools > Preferences > Ping Servers :"

For a nice list of ping servers, check out the above post.

I've added those servers to my live writer, let the massive amounts of traffic begin now. :)

July CTP Conundrum Solved!

Posted in WCF | WPF at Wednesday, August 16, 2006 7:09 AM Pacific Daylight Time

If you're following along the NetFX 3.0 CTP trail, the July CTP leaves you without VS 2005 support. Although you can develop WPF apps in Expression Interactive Designer (EID), the experience isn't quite like the VS experience. However, you can use the June CTP VS extensions with the July CTP (minus Cider) by following Magnus Martensson's instructions:

We have a July CTP but no Orcas? Not true. You can force the current release of Orcas into a machine where the July CTP is installed. This is the command that does it.

msiexec /i vsextwfx.msi WRC_INSTALLED_OVERRIDE=1

You simply tell the msi executable to override the version checking when it installs! Sweet!

Very nice! One final thing that you need to do:

Right click on a .xaml file in your solution and choose "open with...". Choose "xml Editor" and click on "Set as default". Now all .xaml files will open with the xml editor instead of trying to open the unfinished Orcas designer.

Now you can develop your WPF pages in EID and edit your code in VS. This is a big help. Thanks!

PS - How long until we see the August CTP? Will there be one? Are we close to a RC (as mentioned here)?

Tech-Ed 2006 Content Online

Posted in General | WPF at Tuesday, August 15, 2006 9:18 AM Pacific Daylight Time

Just got this in an email:

Dear Bryant Likes,

Tech·Ed2006 Content is now available online at http://www.msteched.com/ click 'Online Recordings'.

Your Tech·Ed 2006 DVD set is scheduled to ship 8/18 and you should receive within 1-3 weeks (depending on your geographic location and customs). 

The DVD set will be sent via the U.S. Postal Service to the address included with your registration information.  
If you do not receive your DVD set within the approximate timeframe, please e-mail TechEd2006_DVD@interactservices.com for further assistance.  
Thanks again for your participation in Tech·Ed 2006!

Tech·Ed 2006 Team

Cool! Now I can attend some of the sessions that I missed...

Update: I'm currently watching Build Beautiful Applications with WPF and there doesn't seem to be any login required for this site. If you're interested in WPF this is a great presentation.

WPF vs. CAB

Posted in .NET | WPF at Tuesday, August 15, 2006 9:09 AM Pacific Daylight Time

I'm starting a new project where we will be using Windows Presentation Foundation (WPF). I've done very little work with WinForms in the past, but from what I understand the Composite UI Application Block (CAB) is the way to go for WinForms development. I've also seen a few posts about integrating the two using crossbow. However, I don't want to host WPF inside of WinForms, I want to use pure WPF.

So does WPF replace CAB as a UI framework or are there things in CAB that WPF is missing?

I haven't been able to find much on the subject so far. I'm just getting started on my project and still learning the WPF basics (and some CAB basics), so it is certainly possible that I'm just missing the obvious answer. Any feedback or suggestions are welcome...

Bryant Likes's Blog v2.1

Posted in General | ASP.Net/Web Services at Monday, August 14, 2006 5:55 AM Pacific Daylight Time

Just upgraded the sqlxml.org blogs to community server 2.1. One of the features that I was interested in was the Feedburner support. I was thinking of using feedburner a long time ago, but I really didn't feel like figuring out all the issues around it. Now it just works! Great job Telligent!

I really like the new skins that ship with this release as well. I even changed my google ads to work with this new layout (and ditched the yahoo ads).

I'm writing this post from Windows Live Writer, which I really like so far (hope it works).

Update: I forgot to mention that I used Sean Winstead's post on using google adsense in community server (and even stole some of his style) to setup my adsense. Thanks!

A Puzzle

Posted in General at Thursday, August 3, 2006 12:15 PM Pacific Daylight Time

From Joe Beda:

Check this out.  Get to 30.  Your day is now shot :)

I'm stuck on 13 right now (and there is a hint in the comments but I haven't looked at it yet). Pretty fun exercise. :)

WCF: Unable to open IChannelListener

Posted in BizTalk | WCF at Wednesday, August 2, 2006 9:51 AM Pacific Daylight Time

On one of my current projects we are trying to use WCF with BizTalk 2006. In order to do this I was trying to implement the WCF adapter for BizTalk Server 2006 community project. The project comes with a nice sample application that demonstrates how everything works. However, when I tried to start the receive port I would get an error message saying:

The Messaging Engine failed to add a receive location "News Receiver" with URL "wcf://http://localhost:13000/eventsource" to the adapter "WCF". Reason: "The ChannelDispatcher at 'http://localhost:13000/eventsource' with contract(s) '"IndigoOneWayReceiver"' is unable to open its IChannelListener."

I tried to get this working a few different ways but nothing seemed to matter. The weird thing was that I could write a simple WCF console app that would listen on http://localhost:13000/eventsource and it would work. But whenever I would start the receive location I would get that error. I posted my question in the WCF Forums and also on the codeplex project but was unable to resolve it.

Then I ran into this same issue again with another sample app that I downloaded, but this time it was because IIS was running on the same port (and I was using Windows XP). However, in the process of figuring that out I came across this post by Martin Parry. While the post didn't resolve my issue (it is for Vista only), it did point me in the right direction. After some more googling I came across this post by dominick baier which explains the issue in Windows Server 2003 terms (and he even provides a tool to help you with the HttpCfg syntax).

So if you're working with WCF and you want to listen on a port and you're not running as an administrator, then you will need to configure the server with the HttpCfg tool. The error message about the IChannelListener isn't very helpful, but maybe that will change before we get to RTM. In the meantime, HttpCfg is your friend.