Geeks With Blogs

News
Geekus Con Livus Malcolm Anderson's home for Geeks With Lives Stupid Code Tricks I don't want to have to search this down again. Anything here should already have been entered into my "Bug Book"
Paste without formatting using a single hotkey
Have you ever tried to copy text from one place and when you try to paste it, it ended up with all the formatting from where you copied from?Word, Excel, and even GMail suffer from this.Normally what you have to do is open up notepad, paste into notepad, select all, copy again, AND THEN paste it where you wanted it.Now you have another option, by using and installing PureText, that entire process has been shortened to Windows-V ......

Posted On Thursday, July 26, 2012 11:29 AM

Excel duration converts to date
I'm working on an Excel 2010 spreadsheet and I'm trying to put in durations for some tasks I want to schedule.The interesting thing is that up until a few minutes ago, I couldn't do it.I was entering in "47:00" and excel was (and still is) converting it to "1/1/1900 23:00:00"In my mind, I want the value to be 47 minutes, but for the life of me I cannot find a fix for this behavior.Here's the weirdest thing, I haven't had this problem in the past. Usually I put in times, add them up and they work ......

Posted On Monday, July 9, 2012 3:24 AM

Getting FxCop 10 to run under cruise control dot net
I don't know who Mikhail is, but his 4 year old entry on FxCop and CCnet was perfect.The only thing I needed to do was to change the references to from FxCop 1.35 to FxCop 10.I was prepared to use Basharat's solution, but it turns out that ccnet version 1.6.7981.1 is already taking care of the FxCop v10 reporting issues ......

Posted On Friday, June 8, 2012 1:16 PM

Installing MSMQ - The illustrated companion
Its been a while since I've played with Message Queuing and C# and decided that I should reduce that counter.During the simple process of figuring how to follow Microsoft's MSDN directions, I ran into a couple of headaches that could have been solved with a few navigational pictures. To the small number of people that this may help (and my future self when I need to do this again) here are the needed pictures.My journey started out with google and the keywords "installing MSMQ", the first selection ......

Posted On Tuesday, January 3, 2012 3:09 AM

Test Driven Development with vxml
It's been 3 years since I did any coding and am starting back up with Java using netBeans and glassfish. Right off the bat I noticed two things about Java's ease of use. The java ide (netBeans) has finally caught up with visual studio, and jUnit, has finally caught up with nUnit. netBeans intellisense exists and I don't have to subclass everything in jUnit. Now on to the point of this very short post ( request) I'm trying to figure out how to do test driven development with vxml and have not found ......

Posted On Friday, January 28, 2011 8:51 PM

Asus Machine fails to start due to missing msvcr.dll - what?
So first off a thanks to the internet, knoppix and a post over at http://www.overclock.net/wi... My Symptoms: my laptop would not boot. Would not let me get anywhere. Just like the symptoms in the post. Thankfully, all I had to do was go rename my avg directory and all was good. But I needed something to boot from and I knew and trusted Knoppix from my past linux experimental days. If it wasn't for Knoppix, I would have probably reformatted my ......

Posted On Wednesday, December 8, 2010 11:30 PM

Setting up Squeeze Pages on Geeks With Blogs
In recent years I have fallen in love with marketing and I'm wondering if anyone has successfully implemented a squeeze page on their GeeksWithBlogs page? What is a squeeze page you ask? It's a simple tool used by marketers to collect your first name, your e-mail address so that they can put you on their list and give you stuff. http://en.wikipedia.org/wik... People put themselves on your list because they find value in what you are saying and they want to be notified when you have more ......

Posted On Sunday, November 28, 2010 9:54 PM

Google Analytics in Geeks With Blogs
Ok, that was cool and somewhat easy. Sign up for Google Analytics add your GeeksWithBlogs (GWB) url (mine is "geekswithblogs.net/geekusc... You will be given a chunk of code. Log into your GWB page, select Options | Configure At the bottom of the page (underneath where it says "Static News/Announcement") paste that code in. Go to a couple of your pages, use some of the navigation. Go back to google analytics and click check status. You should be set. Oh, and if you haven't checked the thirty ......

Posted On Friday, July 3, 2009 5:56 PM

Microsoft Robotics Studio - What?
Once more, Microsoft is handing out free tools, and doing cool stuff, and putting the fun back into programming. This is not a game, it's a full fledged robotics language, and simulator. Ever wanted to show how easy it would be to have robot navigate a maze or program a rescue robot, or a soccor droid? Well now you can. Currently the only one available is the maze navigation (complete with traps), but more will be released over the course of the year. It looks like you can upload your program, and ......

Posted On Monday, June 2, 2008 4:03 PM

Good Bye TDD
Have you seen the new buzz phrase for TDD? Pretty much, they just changed the name from Test Driven Development, to Behavior Driven Development. It's an NLP experiment that I'm looking forward to seeing fleshed out. Long story short, the problem with TDD is the word "Test"... *WAY* too much baggage, and charge on that one single word. Consider: "Testing your code is a good if you're a new programmer" "Our department does testing at the end of a project ... if there's time" "I'm a developer, I don't ......

Posted On Friday, June 15, 2007 12:44 PM

The Perils of Pre-Optimization
More computing sins are committed in the name of efficiency (without necessarily achieving it) than for any other single reason - including blind stupidity.Wulf, W. A. "A Case Against the GOTO," Proceedings of the 25th National ACM Conference, August 1972, pp. 791-97. I came across this quote this morning and had to throw it back out into the wild. I have run into people who, when given a choice between making their code more readable vs. shaving a millisecond off the running time of a particular ......

Posted On Thursday, February 15, 2007 7:52 AM

Alex, I'll take "Google Key Words" for 1000
We've got a custom control that consists of 2 radio buttons, a "normal button", and a text box, all on a single line. Internal to the control, I have all 4 of member controls lined up so that all the text is on one line. So far, so good. Except for one thing. When I put my control on my form, I can not get the text on my form to line up with the text on my label, and I end up manually futzing it into something that resembles "it's place". Where are my alignment functions? I guess it's off to google. ......

Posted On Thursday, June 14, 2007 11:23 AM

Non Click-Once Version Pain
Aaaaaaaaaaaaaarrrrrg Apparently with the release of VS2005, Microsoft has decided that if you are not using click once, you obviously don't need to use version numbers on your app. I'm trying to set up a schema of 1.2.3.4 where 1 = major 2 = minor 3 = sprint number 4 = ccnet build number but no matter what I do, when I right click on MY_APP.exe, and check properties, I get "1.0.0.0" as opposed to my expected "0.5.5.298" On the other hand, another one of our apps is deployed using click once. That ......

Posted On Friday, May 18, 2007 12:34 PM

FitNesse command line issues with .Net 2.0
There seems to be a small handful of people who are using FitNesse with .Net 2.0 and a smaller handful (me included) are having issues with the fitness command line tool (TestRunner.exe) The error is Type <yourTestTypeName here> could not be found in assemblies. I posted the following comment over at Cory Foy's APress blog in his highly useful entry Getting up and running with Fitnesse.NET If anyone else is either having these kind of problems or if you have solved this problem, please let ......

Posted On Thursday, May 3, 2007 1:27 PM

Using NantContrib's msbuild task
I'm in the process of trying to make a copy of tree surgeon that does a couple of different things. (If you don't know what tree surgeon is and you're a dotnet developer, I can not say enough good things about it, go, run, don't walk, get it) One: I want to implement Jean-Paul Boodhoo's version of the Model-View-Presenter framework which he presented in DNRTV episode 14 Two: I want to provide a Console, a WinForm, and an ASP.Net front end. Three: I want to upgrade treesurgeon to 2005. In light of ......

Posted On Saturday, February 3, 2007 4:47 PM

Windows Media Player "Feature"
So last night my windows media player developed a fascinating bug. Prior to last night, I could play a movie in one screen and do work in the other. But not anymore. A Computer Express article from July of 2004 (Try the cached version here) had this to say: "3. Video playback Windows Media: Windows Media Player automatically detects the availability of a double display configuration. When you play the media clip (videos, DVC, VCD) Media Player automatically plays it in full screen mode on the secondary ......

Posted On Tuesday, January 2, 2007 8:53 PM

A tool for capturing testing objects
I posted my code for a serialize and I just thought up an idea for making it really useful. I'm retroactively trying to add some unit tests to some legacy code. I've got a working version of the code, and I'm thinking that I need to add a method or two to my serialization tool. First thing, is I need a way to put a bunch of save hooks in and then have it trigger for all my objects that I care about catching their state. I'm thinking a static boolean that can be set on with a test for a field being ......

Posted On Monday, July 24, 2006 12:34 PM

My Session was small, but it rocked
Friday night, my presentation congealed into garbage. This was not a good thing. I had to skip Jeff Levinson's “Test Driven Development with Team System” in order to work on my presentation. I was competing with “Poker Bots for Fun and Profit”, with Jeff Berkowitz, Stuart Celariar's “Understanding Subversion“, Rory's “An introduction to WCF for the complete beginner“and 4 others. There was a part of me that was hoping that no one would show up, because ......

Posted On Monday, July 24, 2006 5:49 AM

Object serialization in VS 2003
I don't know about you, but I have an attention span that is about 20 minutes long. If I can get your sample working, doing something (anything) in the first 20 minutes, I may be playing with it when the sun comes up. You just have to capture my attention QUICKLY. In that light, I wanted to post a utility that I wrote to make unit testing mo-bedda (read : easier) This consists of the class, and the unit tests to exercise the class. If all goes correctly, you should be able to copy these into new ......

Posted On Thursday, July 20, 2006 12:35 PM

Unit Testing a Private Method
So on a lark, I threw my hat into the ring for Portland Code Camp 2.0, I didn't expect to get accepted, there were already a few sessions on unit testing and nunit but I figured, what the heck, let's gear it for beginners, and do it in VB.Net. Now I'm in the process of getting ready and I figured I should blog about things and or techniques as they came up. For my first trick, testing a private method. First rule of thumb: Don't do this. No really, Don't. You are locking the internals of your code ......

Posted On Thursday, July 13, 2006 7:48 AM

Wrox "C# Threading Handbook" Errata - Part 3
I'm still enjoying the old Wrox “C# Threading Handbook“ I just wish it was still supported. I kinda wish they would update the whole “Handbook“ series for VS2005. The only problem is that their original price point was a little high. There were something 8 or 12 books in the series, and I've had no problem paying $5 - $13 dollars for them used. And I'd probably be willing to go $20 - $25 on them new, but the list price in 2003 for the 260 page threading handbook was $40.00. ......

Posted On Wednesday, May 31, 2006 12:05 PM

I need input on Unit Testing Architecture
How do you set up your classes, and your file structures? Below is a 1 sheet “handout“ that I'm preparing for my talk on Saturday. It's really more of a handful of thoughts about how I want to do things rather than a suggestion. Tools and methods I want all my classes to have. Given Class Foo (and instatiation of myFoo) myFoo.SaveSelfToDisk(“... myFoo.LoadSelfFromDisk(R... Foo newFoo = myFoo.Clone() Bool areEquals = (myFoo.IsEqualTo(newFoo) ......

Posted On Wednesday, July 19, 2006 5:47 AM

Portland Oregon Code Camp Needs You
Do you live with in 200 miles of Portland Oregon? Do you have a subject related to programming that you are passionate about? Are you a geek with a hidden desire to demonstrate to the world that you know what you are talking about? Are you available to be in Vancouver Washington this Saturday and / or Sunday? If you or someone you know fit's the above description, we need you NOW. Run, don't walk over to the Portland Code Camp site and sign up to give that presentation you've always wanted to give. ......

Posted On Tuesday, July 18, 2006 10:21 AM

Wrox "C# Threading Handbook" Errata - Part 2
On page 47 of Wrox's "C# Threading Handbook" in the code listing for the GenerateText method, you will see that each string builder append line starts with sb.Length. Just remove the sb.Length and the code will run fine. If anyone knows some one at Apress, who handles the errata for their old wrox book, I would like to be able to put this errata in a more centralized location. Thanks Here's the code listing. using System; using System.Threading; using System.Text; namespace TimerExample { class TimerExample ......

Posted On Monday, May 29, 2006 10:49 AM

A facinating site.
http://www.memecentral.com/ Richard Brodie's name came up in an unexpected place recently and I ended up at his web site. "Welcome to Meme Central, the center of the world of memetics. Memes are contagious ideas, all competing for a share of our mind in a kind of Darwinian selection. As memes evolve, they become better and better at distracting and diverting us from whatever we'd really like to be doing with our lives. They are a kind of Drug of the Mind. Confused? Blame it on memes." All I can say ......

Posted On Wednesday, October 26, 2005 8:40 PM

Wrox "C# Threading Handbook" Errata - Part 1
According to the Apress Support page, there is no Errata for the C# Threading Handbook. This is too bad because that means that there is no central repository for errata, code listings and other stuff for this really great book. Here is the first real bug I've found in this book. On pages 44 and 45 you will find a listing for the ThreadPriority2.cs file. Here is the corrected code. using System; using System.Threading; namespace ThreadPriority2 { class ThreadPriority { public static Thread worker; ......

Posted On Sunday, May 28, 2006 10:45 PM

SQL Server Reporting Services - Interface issues, part 2
I ranted a but a few weeks ago and I'm just wondering if anyone else is running into these issues. First, SSRS is amazing. You can do things on the back end that are incredible, deployment is taken care of and all you can say about it is WOW. The front end is a very different matter. It reminds me of this article on Lotus Notes, where 95% of the user think it sucks, and why it survives (Finding the link to the guardian article had me come across this rebuff which is just as interesting) Anyway, this ......

Posted On Tuesday, February 28, 2006 3:40 AM

SQL Server Reporting Services Frustrations
A year and a half ago, I saw a demo of Microsoft’s Reporting Services and said, “Crystal Reports will be a memory in 10 years”, and I still think I'm going to be correct. *However* Crystal doesn't have much in the way of worries right now. For the last couple of weeks, I'm working with SSRS for the first time, and WOW does it suck. Don't get me wrong, the infrastructure is fantastic. Moving a report from drawing board to server is simply a right click and a “deploy“ ......

Posted On Sunday, February 12, 2006 9:33 AM

NMock and the Heisenberg uncertainty principle
Something interesting with NMock. If you set an ExpectAndReturn block and then set a watch on that value, you could will end up with a NMock.VerifyException. Here's what's going on. When you set the ExpectAndReturn, like this one fooMock.ExpectAndReturn( “LoginEnabled“, true ); you are saying that you expect your mock to check the value of LoginEnabled one time. If you want to use that value twice it would look like this: fooMock.ExpectAndReturn( “LoginEnabled“, true ); fooMock.ExpectAndReturn( ......

Posted On Monday, August 1, 2005 9:42 PM

Was it that hard to document?
All I wanted was to take a numeric string, and increment it. The string happened to be 2 digits long. All I wanted to do was something along the lines of var.ToString().PadLeft(2). So off to google I went, and I finally found my answer, but not in any MSDN documentation. The MSDN docs refer to format strings as if I use them EVERY single day. I don't. I deal with them about once every 3 months, (but this time ... I'm writing it down) I eventually found this method stringVar = intVar.ToString().PadLeft( ......

Posted On Tuesday, July 5, 2005 5:02 PM

Serialization and Unit Testing
This one is going to wander a bit, just a warning. Ok, You’ve been warned. So one of the things about being in exile out here in the middle of the Atlantic is that I’m getting a chance to catch up on my DotNetRocks listening. Right now I’m about 15 months behind (That would be October 2004ish) and just got done listening to show 86 with Juval Lowy. (As a side note, its interesting to notice that so far, I don’t think there is a single show that should be marked “obsolete” ......

Posted On Thursday, January 26, 2006 12:31 AM

Getting NMock to do a collection
The documentation on NMock is scanty at best, non existent at worst. Add into this mix that I self identify as a Mort. Someone who is generally more concerned about grabbing the data a customer wants and displaying it the way she wants it, so that I can pick up my pay check and go enjoy spending my money. Apparently, this combination has left me in the position of trying desperately to find example code to improve my oop skills while at the same time, educating me in exactly how weak my those skills ......

Posted On Wednesday, August 3, 2005 11:29 PM

Copyright © Malcolm Anderson | Powered by: GeeksWithBlogs.net