November 2005 - Posts

-> Wow.

I played with ClickOnce deployment for a little while earlier. After getting a couple of files/dependencies worked out, I had a fully installable ClickOnce application. It didn't let me specify where I wanted to install it, but I guess that's part of the deal for auto-updates etc.

I'm going to have to investigate this further...I knew ClickOnce was supposed to be cool, but easy too? Get outta here.

[ Currently Playing : Come Back - Foo Fighters - One by One (7:49) ]

NEW: "PostXING" in about page now links to

NEW: FTP Settings page now is labeled as such. This was confusing in the new user wizard.

FIX: Plugin ToolStripButtons now actually do something.

These are a couple of the things that I've fixed this morning based on some really great feedback from a few really brave souls. The most work it looks like is still going to be the options story. I knew this was going to be the case when I announced the alpha, so thanks everyone for your input!

In an attempt to work on steps 7 and 8 in Grant Holliday's Blog, I've started a community server site for PostXING.

It's lite on content at the moment, (and also may not work everywhere for the next couple of days thanks to DNS) but hopefully this will let me address number 7 via the forums and number 8 via the gallery.

6 is done - actually using the default browser for the view blog function. I think I'm doing pretty well for number 5, and number 4 should probably be implemented in a couple of more places. Number 1 is a big duh and should have been done since day one. 2 sounds like an interesting problem and will require a little more thought (although initially I'm thinking something like the auto-saved draft feature in gmail)

And I know it. I haven't updated the binaries on ProjectDistributor for a long time because I've been taking my time writing v2. Thing is, it's starting to catch up to me.

PostXING v1 is far from polished. It works well enough for my needs and I made it available for download in the hopes that it would be useful to someone else, nothing more. But I do want to make it a better application, and that's where you, dear reader, can help me out a little bit. I've decided to release an early alpha of PostXING v2 in the hopes that doing so will help it suck less than v1.

What's in it for you? Well, the same thing that's in it for me: if you catch some nasty behavior that I've missed then PostXING becomes a better product for everyone who uses it (all two dozen of ya)

If you're interested, contact me with the subject "PostXING alpha request" and I'll send you a zipfile with the new bits. The program requires v2 of the .NET framework.

Thank you.

Since announcing that we've started the beta of our implementation of the MetaWeblog API for MSN Spaces, I've received a bunch of positive responses from a couple of blogging tool developers. So far it looks like there'll be at least six blogging tools users will be able to use to manage the blog on their space after we launch the API.

[Via Dare Obasanjo aka Carnage4Life]

Add at least one more - PostXING v2 will work with MSN Spaces via the MetaWeblog API. I don't think that it will work well with previous versions because I had to change some code in to handle the BOM as I noted earlier. If the library was updated for v1, I'm sure it would work there as well.

Ah! It's been a while since I've gotten some good PostXING feedback. Guess the current version isn't very keyboard-friendly. I'm probably not going to upgrade the v1 code in v1 of .net, but I've been working for the past couple of weeks on getting PostXING to v2 under .net v2, so none of these requests are out of the question. As a matter of fact, I welcome all criticism in the hopes of making PostXING a product that works really well for more than just myself. Anyways, Peter has some good feedback for PostXING in general, my responses follow his post:

I decided today to try out PostXING as an alternative to BlogJet. So far my reaction is mixed.


  • Seems to have good WYSIWYG support
  • I like having the standard HTML heading tags available in the toolbar.
  • I can easily insert a horizontal rule in my post
  • I love the fact that it has the CodeHTMLer syntax hilighting engine in it, but it doesn't feel quite as smooth to me as BlogJet does.
  • I'm very glad that it supports uploading images via FTP in the same way that BlogJet does. This is a must have in my book.
  • As with BlogJet, I can't open an arbitrary post by ID. I have to find it in the historical list of posts, which sucks when the post is from a year ago.


  • I have to click a button and wait for a popup to set the post's categories
  • I can't use TAB to navigate the UI which means I have to use the mouse (a serious usability error as far as I'm concerned). And I don't know if I agree with the idea that TAB causes BLOCKQUOTE in the resulting HTML.
  • I can't find keystrokes for many of the standard formatting things like ordered and unordered lists, styles, etc.
  • Sometimes after using CTRL+K to format some text as a link (good), the input focus leaves the text editor and goes up to Title field (bad).
  • I can't figure out how to post with a keystroke. It should be CTRL+Enter (like Outlook and BlogJet) but it isn't.

This will be my first post with it, we'll see if it is also my last. If the author can fix a few of those cons, I would be considering switching. For now though, I'm not so sure.

This seems like such a simple problem... I can't believe how poor all the choices really are.

[Via Geek Noise]

I'll try to address these as best I can, starting with the last Pro...

    • This is a drawback of the MetaWeblog API, which is why you see the same behavior across both BlogJet and PostXING. The only way to really get around this is to use a different API to access your blog, like perhaps the webservice API in CS. Hopefully when CS v2 drops I'll be able to code up a plugin/provider that allows native access to the webservice api instead of having to use mwb all the time.
    • In v2, the popup is replaced with a "Container Bar", but it's still the same concept. How would you rather see the category feature implemented? Perhaps as a dropdown next to the title kind of like w.bloggar?
    • PostXING does capture the tab key in the editor surface to create a blockquote: I did this to be able to format quotes quickly. Maybe it was a wrong decision, but this is the first time that I've ever heard anything bad (if a Con is bad) about it. I could for sure make this configurable, but what should the default behavior be? Insert 4 spaces, or be able to tab around the rest of the application? I guess at the time that I implemented the tab capture, I figured the editor experience was the main focus of PostXING.
    • You can't find these keystrokes because they don't exist. What should they be?
    • This is 100% mshtml code (especially the ctrl+k part). I don't know how to address this but like all of the other points I'm open to suggestion.
    • Again, there is no keystroke for this. Sorry. :( I will for sure add ctrl+Enter support, but which button should this be associated with? Post or Post & Publish?
One or more errors encountered while loading the designer. The errors are listed below. Some errors can be fixed by rebuilding your project, while others may require code changes.

The designer loader did not provide a root component but has not indicated why.


at System.ComponentModel.Design.DesignSurface.get_View()
at Microsoft.VisualStudio.Shell.Design.WindowPaneProviderService.CreateWindowPane(DesignSurface surface)
at Microsoft.VisualStudio.Design.Serialization.CodeDom.DeferrableWindowPaneProviderService.CreateWindowPane(DesignSurface surface)
at Microsoft.VisualStudio.Design.VSDesignSurface.Microsoft.VisualStudio.Designer.Interfaces.IVSMDDesigner.get_View()

 It looks like there are a lot of people that got this error when going from beta2 -> RC1, but this was on the RTM version. The thing that's tricky is that now the designer is so nice for us, it adds default values to public properties. Well, since the code that was being called was basically a wrapper for mshtml, I guess you could say COM was involved (like a third cousin). In order to find this bug (in my code, but my code generated by VS2005.) I had to fire up another devenv.exe instance and set it to attach to the first devenv's process for debugging. I don't know the exact workaround for this yet...maybe making the particular property that was causing trouble readonly w/ an accompanying SetProperty(value) method that would still let the underlying value be set. See the problem is that VS regenerates all that goodness for me, so whenever a change is made and saved in the designer I would be facing the same problem, have to hunt down one line of code, and start over again. Boo.

Is there a way to turn off the designer's new behavior?

I'm using as the library that supports xml-rpc for the MetaWeblog api in PostXING.

I recently ran into a service endpoint that included a Byte Order Mark in the payload of the response. Something I haven't run into yet basically because the few blog engines that I have tested px with have not included this. It turns out that the XmlDocument.Load method that accepts a stream doesn't take this into account (or something:).

So this is what I did to workaround the problem: basically, if the first character is not <, the second must be otherwise the content is invalid anyways.

//...the DeserializeResponse method that accepts a stream
StreamReader sr = new StreamReader(stm);

string content = sr.ReadToEnd();

if(content.Trim().Length > 0 && content[0] != '<'){
	content = content.Substring(1);

StringReader str = new StringReader(content);


The other endpoints still work after this modification, so I guess it's okay.

update: there was an indexoutofrange exception just waiting to happen up there.

Disclaimer: the code for showing the color menu is totally ripped off of a CodeProject article. I just took the ColorPanel part and parented it with a ToolStripButton. The idea works, tho.

Here's the source: ToolStripColorButton.cs (login is guest/guest).

I've been working recently to bring PostXING v2 to .net v2. Part of this process has shown me that Divelements' SandBar menu system (the last freeware version) doesn't like to be in a nested UserControl after a recompile. Throws all kinds of errors that are obfuscated and painted directly on the control in the designer. Unfortunately, I can't try a newer version of SandBar because they discontinued the freeware versions that they used to have. Shame, it's a really good library.

So anyways, I find myself needing a similar experience to the ColorMenu that I extended that comes as an example with the trial download. Now that we have a first-class menu system in System.Windows.Forms, I decided to see if I could create something that kept the simplicity of the ColorMenu. The ToolStripColorButton simply has a subclass called ColorPanel that inherits Form. When you click on the button, the form is shown. When a user selects a color, a changed event is thrown and you can do what you want with the resulting color by handling this event:

private void btnFontColor_Changed(object sender, EventArgs e)
	this.DesignEditor.TextFormatting.ForeColor = this.btnFontColor.Color;
A couple of points that could be extended: The gradient background looks all wrong with the default XP themes. I wonder if there's a way to query what the start/finish colors are for the current theme w/o going into unmanaged code? Heck, even with unmanaged code (via P/Invoke) would be fine. This same problem shows up for the GradientPanel I recently posted. Something to look into, anyways. There's also the extension point of adding the actual color as the image instead of using a stock icon or something similar. The code to do it is basically in the CodeProject article linked above, I was just happy with the icons for my current purposes.

[ Currently Playing : Drive Slow (Feat. Paul Wall & - Kanye West - Late Registration (4:32) ]

Is the insert snippet chord in VS 2005.
More Posts