Jakew
Consulting, hacking, and motorcycles

New rig

Wednesday, 28 February 2007 09:35 by jakew

My new machine arrived yesterday.  I ordered a Dual XEON Duo with 4Gig or ram and a 10KRPM SATA drive.  It also has two NVIDIA 7600GTs in it to drive my monitors (3 20” LCDs). 

 

3 screens

I went ahead and move to VISTA Ultimate which went in without any effort.  Everything worked nicely and took less time than I expected.  The biggest change is that I’m going to attempt (again) to keep all my servers running in VPCs.  I looked around the net and saw that VPC 2004 had some issues on Vista so I installed 2007.  I think it doesn’t like glass being turned on.  I’m cleaning up my other drives (2 SATA drives from my old machine) so I’ll play around with it later.

My impression of Vista is way better than I had been lead to expect from reading the pundits.  That just reinforces my tendency to think that Pundits are washed up has beens who are too lazy to actually research what they are talking about.  Sorta like I can either be an excellent consultant and software developer or I can be a excellent blogger.  Pretty obvious what my choice is.

Oh, and iTunes works fine.  I also read a lot of comments about iTunes not working right on Vista.  As usual the dorks blamed Microsoft.  It isn’t like Apple should take any responsibility for maintaining their software.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

How I’m making my presentations for YouTube

Tuesday, 20 February 2007 22:48 by jakew

I'm doing this on the thinnest of budgets and with very little time to invest.  However, I think the product is OK.  Better presentation technique on my part would make up for the way I'm doing this.

What I'm doing is pointing a video camera at an LCD monitor.  That is it.  The resolution of the monitor doesn't seem to make that big of a difference.  Plus the fact that YouTube does 320x240 for the videos doesn't help me any.  But you can generally see what I'm doing and follow along.

Overall, I'm having fun making this stuff and don't seem to have any trouble coming up with topics to talk about.  And for future fun: I have a helmet camera on the way.  Then I can jabber on endlessly as I ride to work.  Visual Studio at rush hour.  Should be interesting.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

Beyond the Red Dot

Tuesday, 20 February 2007 22:38 by jakew

During my presentation about Visual Studio extensibility I found out that a lot of developers are not fully aware of the powers of the break point.  I plan to help correct this and demonstrate the wonders of the Visual Studio debugger for all to see.

Generally speaking most developers get along in life by either clicking on the left most column in the editor or hitting F9 to create a break point.  This creates a location break point which will cause the debugger to stop on the line of code.  Every single time it visits the line.

You can live this way pounding F10 until the bones in your index finger grind themselves down to dust.  Or you can take the small step beyond and use the four other break points available to get your job done.

The first one to consider (and my personal favorite) is the conditional break point.  As the name implies it causes the debugger to stop if conditions are met.  To get this type of breakpoint, first click in the left gutter or hit F9 and then right click on the red dot (or go through the menus if you prefer).  A context menu will pop-up offering you several choices.  For now go with Condition.  In the dialog there is a text box  for you to enter the condition.  You can have some fun here because you can call functions, create Boolean expression and compare things.  For instance you could have a function that returns a bool value that goes out and determines if you are close to the last record in a database.  If you are then it returns true (say for the last 5 records or the last name of the record == "Jones").  Or you could just compare two values say  Record.LastName == "Jones".

Also pretty cools it that you can set the break point to only break if a variable changes.  C++ developers should find this one useful.  To demonstrate it, setup the breakpoint for _SomeVariable. When your program starts it is set to false, on a button even you change _SomeVariable to true.  When that happens the debugger will break.  You still  have to set the break point's location to the line that is changing the value but that is pretty minor.

Next up is the Hit Count break point.  This one is really is to use in loops,  throw down the dot, set the count to whatever value you need and let your code go.  The debugger will stop when it has passed the break point however many times you set.  This isn't just useful in loops though.  If you have a function that should only be called one time, a hit count break point would be pretty useful to catch that second call the blue screens your workstation.

Filter breakpoints (like the abrupt transition?) are used for multithreaded debugging.  You can specify which thread you want the breakpoint associated with.  I've not played with this one so I'll not shoot my toes off talking about it more.

The last break point - When Hit - is pretty cool.  This break point allows you to call a Macro from the break point.  Via the dialog you can also have it print out a debug trace statement so you can follow the execution of your code. 

 I'm also posting a video of this presentation on YouTube.  The program is still encoding it so it won't be available until tomorrow (probably).  The presentation materials are also going up.  If you would like to use them please contact me.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

BizTalk Pipelines and debugging

Wednesday, 14 February 2007 15:26 by jakew

I’m working on a little project that involves a BizTalk pipeline that can configure XmlDasmComp for whatever message is going through the pipeline.  The pipeline sniff’s the message and sets up the envelope and document schema and then lets XmlDasmComp do it’s thing. 

Generally this is pretty simple stuff, but it totally threw me for a loop because every time I ran it in the debugger I would get a COM+ Exception from XmlDasmReader.  I used Reflector to spy on XmlDasmReader and I learned that the exception occurred when it was trying to get the Document spec I had specified.  Unfortunately I couldn’t quite find the code that was actually loading the Document spec.

So I threw together a simpler version of my component, one that hard coded the schema.  Same thing. Absolutely no explanation. 

In desperation I compiled and ran the SchemaResolution sample included in the SDK.  It worked!  What was the difference?  Pipeline.exe versus running inside BizTalk.  Apparently whatever loads up your schema (IDocumentSpec) needs a connection to the BizTalk management database.  In hind sight it makes perfect sense.  But the past 24 hours have been hellish for me.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

Best developer book - Debugging Applications

Monday, 12 February 2007 19:24 by jakew

In my talk about Visual Studio Extensiblity I mentioned an excellent book that I think everybody should read (at least software developers).  The title is "Debugging Applications for Microsoft .NET and Microsoft Windows" by John Robbins.  You can get it here from Amazon

I'll have a YouTube vlog up about the fun you can have with Break points pretty soon. 

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

VSEXT videos are uploaded

Sunday, 11 February 2007 20:51 by jakew

I finally uploaded all of the files to YouTube.  They should be ready by morning. 

 Just search for GuerillaProgrammer on YouTube and you'll find my stuff.

 

Let me know what you think.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

The rest of Visual Studio Extensiblity

Sunday, 11 February 2007 10:30 by jakew

I just finished shooting the rest of my visual studio extensibility videos.  They are being converted now and should be on YouTube later today.

 

Hopefully I’ll get some feedback on how to make these better.  I want to keep things as simple as possible and am not too interested in spending money on this.  So with in those parameters – what can I do better?

 

Also, what topics would be interesting?  I am about to do a series on BizTalk covering things like custom pipelines and adapters, and a few Orchestration tricks.  I’m also thinking about digging deeper in to the VS debugger.  I started to talk about break points in this set but cut myself off.

 

One thing I learned as I did this is that making a video isn’t as easy as it appeared.  The actual shooting part is a pain.  I hate being on video which is why you don’t see me in the videos anymore.  The other part is rehearsal, part of keeping it simple it shooting from the hip.  Which means that the video is going to be one continuous stumble.  That will turn off a lot of viewer.  I honestly couldn’t care less.  The info doesn’t change, it just becomes more hip in the presentation.  I hate hip and usually hip is shallow.  I would prefer to be right and appear foolish than look hip and be wrong.

 

What am I using to make the videos:

 

I have a Sony DCR-SR40.  It shoots very nice MPEG2 video which I can download via USB2.  The camera basically becomes an external hard drive when I plug it in.

 

The editing is being done using ULEAD VideoStudio. I’m still using the Trail version but I’m going to buy it.  For $99 I think it is a pretty good package.  Windows Movie Maker would have worked fine but I couldn’t get it to work with the MPEG2 coming from my camera.  I would have had to buy another program anyway.  VideoStudio seems to just a little better and lets me do everything in one place.  I like that. 

For my skill level I don’t think anything more would make sense.  Adobe’s FinalCut for instance would be way overkill.

I also looked at the freeware out there.  None of it looked that good and most required more money to do what I needed.

 

One thing I could do differently is record directly from the screen.  Right now I just point the camera at my monitor and record that way.  It seems to work ok (good enough, not great).  I could use the Windows Media Encoder package to capture the screen to video.  That would put an end to me zooming and panning the camera around.  I might do that, but then I would be forced to do more editing than I currently have to do.

 

Feedback on how I can improve this would be greatly appreciated.  Topics too.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

Dallas .NET User's Group Presentation - Visual Studio Extensions

Thursday, 8 February 2007 21:44 by jakew

I delivered my first user group presentation earlier this evening.  It went fairly well in my opinion.  The audience was really nice to me and participated.  That made things so much easier.  I've spoken to groups that just sat their and stared.  No fun at all.  this group though was fun.

 The topic I spoke about was how you can extend Visual Studio.  The way I chose to do it is primarily by writing C# Add-in projects.  In my presentation I demonstate how to write an add-in that generates NUnit tests for whatever file you have open.  Another one sets breakpoints on all of the lines you have selected and my final demo puts a header at the top of you file (everything was being done in C#).

 The presentation files are available here.

If you happened to be at the presentation: thank you very much.  Everybody played along very nicely.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

Visual Studio Extensibility part 2

Thursday, 1 February 2007 23:03 by jakew

Actually, this is the introduction.  I just sorted started in the middle and am working from there.  

 

Here is the link:

http://www.youtube.com/watch?v=VOSCO-ZWp9w

 

Tomorrow I’ll finish this up.  I have some good samples that will hopefully get people writing macros and add-ins.

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed

Extending Visual Studio Part 1

Thursday, 1 February 2007 21:14 by jakew

I'm starting in the middle because that is the way I do things.

I'm getting ready to do a presentation on the ways you can extend visual studio.  My reasoning is that you should use VisualStudio as the starting point and build tools on top of it to make yourself more productive.  Early versions of VS didn't make this easy, but with the .NET versions and 2K5 things are easy. 

This first video talks about the simplest way to extend VisualStudio - just use the external tools features.  As I say in the video it is sort of lame that I'm even mentioning it, but it deserves some love.

http://www.youtube.com/watch?v=Yt5Vuum0bAQ - I tried to embed the video but it didn't work for some reason and I don't feel like figuring it out.

I'm in the process of shooting more videos.  YouTube requires that videos be shorter than 10 minutes.  Initally I thought that would be a pain.  However, it turns out to be a good thing because it forces me to get to a point quickly.  Even so 10 minutes is longer than you think.

 

 

Categories:  
Actions:   E-mail | del.icio.us | Permalink | Comments (0) | Comment RSSRSS comment feed