About the author

Steven HarmanSteven Harman is a passionate developer who believes that writing great software isn't just a job, its a craft.

ASP.NET MVP

For recent posts and more about me, scroll to the bottom.

Subscribe

  • Subscribe to my feed. via RSS
  • Subscribe via email via email

Jobs

Badges

  • Subtext Project
  • Support Subtext
  • HiddenNetwork.com Banner

trick

There are 15 entries for the tag trick

Visual Studio Usability Tip: Highlight Current Line

This may seem like a completely obvious tip to some, and like a complete waste of time to others. But you know what? Its something that I've found extremely useful so I'm going to share it anyhow. Hey, this is my blog and I can do what I want! :) Update: I forgot to explain how to enable Highlight Current Line in the original post. I've now added instructions. Highlight Current Line This feature is not available in vanilla Visual Studio - its part of my favorite zero-friction productivity enhancer, ReSharper....

Visual Studio Tip: Kill that Build!

At the day job I spend the majority of my time in Visual Studio, writing, refactoring, debugging, and banging my face against code. C# code specifically. And what is my #1 complaint about C#? The Compilation Tax. I get over taxed! I have a little problem that causes me to pay that tax more often that I think I ought to. I have some kind of weird internal clock that causes my fingers to issue the Ctrl + S, Ctrl + Shift + B keystrokes every five minutes, causing the IDE to freeze up while it...

Search Driven Uninstall for Visual Studio 2008 Betas

Like everyone else, I’ve been playing the uninstall-before-we-install dance in preparation for the new Visual Studio 2008 bits. One hott tip for getting the uninstall part right is to follow ScottGu’s excellent post, Steps to Uninstall VS 2008 Beta2 before installing the VS 2008 Final Release. One pseudo-problem that my co-workers and I have run into is trying to find those particular programs in the huge list of programs in the list of programs on your box. It’s like the old needle in a stack of needles problem. Search Driven Navigation If you’re running on...

Setting Visual Studio Split View Defaults

I’ve been using Visual Studio 2008 to do my Subtexting and while I’m really digging some of the new features like JavaScript IntelliSense, there is one new feature that is just driving me nuts. Split View. By default VS 2008 opens HTML documents, which includes .aspx, .ascx, and other markup document types, in the split view. Split view is great if you’re interested in working in the design surface and still want quick and easy access to the raw markup responsible for creating the pretty UI. However... I’m deathly allergic to the design surface and try to avoid...

Quick Tip: Clear You DNS Cache

Need to clear you machine’s DNS Cache? Running Microsoft Windows? It’s pretty simple and straight forward. Fire up a Command Prompt† Run the following command > ipconfig /flushdns You can also take a look at what’s in your DNS resolver cache with the following command > ipconfig /displaydns Why would you clear your cache? Most DNS clients will cache the results...

Calling Tech Support? Speak Phonetically, Save Time

The tech support for a certain large computer manufacturer, who shall remain nameless... but their initials start with an H and end with a P, recently stole more than eight hours of my life. Yep, that’s a whole work day’s worth of my life that I’ll never get back. Sound familiar? It should. Anyone who has ever owned or been responsible for any significantly complex piece of technology and/or equipment (read: magic) has at some point called tech support or customer service. Calling tech support/customer service is never fun. No one likes to spend their already limited...

How-To: CTRL + ALT + DEL in Remote Desktop

I’m a big fan of Microsoft’s Remote Desktop - it’s built right into Windows and allows me to quickly and easily administer a remote box from the comfort of my own work station. I use it at my house to administer the headless servers on my home network, the Subtext build server, and the co-located VelocIT servers. Gotta' love that magic! Today a co-worker asked me how to send the infamous Control + Alt + Delete keystroke combination to a machine he was working on via RDP. This is a pretty common keystroke to use when trying administer windows... it...

Setting a Default Browser for Visual Studio

My dev box recently decided that all USB devices - along with several other pieces of hardware - were inherently evil and in the end I decided to just repave the machine. It has been about 6 or so months since I first moved to Vista and it was time for a fresh install anyhow. After reinstalling and configuring my box I sat to do some real work (hey, I gotta' pay that mortgage). So I fired up Visual Studio and got busy. I work primarily on web applications and I have a few browsers installed on my box...

Visual Studio: The Output Window, External Tools, and a Gremlin

I’ve been using SubSonic for a while now and I totally love it. Not only has it made developing in .net fun again, it’s also been a huge productivity booster for me and the guys I work with. And while I appreciate all of the hard work that the team has put into the SubSonic Build Provider for use with WebSite Projects, I just don’t work that way. I like having the actual generated code files included in my project (be it a WebSite or WebApplication) and checked into source control. I gives me the warm and fuzzies. But...

Hardware Problems: My eSATA + SATA II Enclosure Won't Play Nice

Tonight I wasted several hours troubleshooting hardware/driver issues with my development box - a fully loaded Dell OptiPlex GX620. I've been fighting with this particular machine since the day I got it. Recently it's been freezing up, the USB controllers malfunction at random times, it hangs during boot (before the OS even starts loading), and all kinds of other fun stuff. I've already upgraded the BIOS to the latest available version, released back in December 2006, and applied all relevant firmware and chipset driver updates. Oh, and I'm running Vista Ultimate 32-bit... though I had the same hardware issues...

Add Option Elements to a Select List with JavaScript

While working on a web application I had the need to dynamically add new Option elements to a Select element (drop down list) using some fancy client-side JavaScript. The obvious solution was to do something like this: var theSelectList = $('theBigFatSelectList'); var myNewOption = new Option("My Option", "123"); theSelectList.selectedIndex = InsertNewOption(myNewOption, theSelectList); function InsertNewOption(newOption, selectElement) { var optsLen = selectElement.options.length; selectElement.options[optsLen] = newOption; return optsLen; } And it worked just as I’d expected. I got a new option in the drop down list and all was right with...

Some Small Ways to Reduce Daily Development Friction

Brennan recently posted a great tip for changing the RSS Feeds that Visual Studio displays on the Startup page. Finally I can get rid of those horrible Microsoft articles and get some good content in that window! I quickly realized that many VS users probably already knew about this, but to many others, self included, this was totally new. And what's more, it's useful! So with that in mind, I decided I would start sharing some simple tips, tricks, and shortcuts that I use within the VS IDE and Windows environment to reduce the friction of many day-to-day development tasks. Open Containing Folder...

URL and HTML Encoding on the Client? JavaScript to the Rescue!

Phil recently wrote about some of The Most Useful .NET Utility Classes Developers Tend to Reinvent Rather Than Reuse - an article chock full of tasty tips, tricks, and reminders about [.net] framework features you forgot (or never knew) existed. One of the utility classes Phil mentioned was the System.Web.HttpUtility class. Two of the super useful methods this class offers are UrlEncode and UrlDecode... used to uh, convert a string into a URL encoded string and decode a URL encoded string, respectively. Do you encode? All web developers, regardless of language/platform, should be intimately familiar with the basic encoding schemes...

Tip: Put Connection Strings in Their Own Configuration File

asp.net 2.0 introduced a new section in the web.config file -ConnectionStrings. This new configuration section allows you to add connection strings in your web.config, like we always have, or in a different data source. In Subtext 2.0 we're using this new feature to split the connection string out into a new configuration file, user.config. Doing this should make day to day development easier for our development team by reducing the number of merge conflicts in web.config. Since most every developer has a different database configuration, it makes sense to keep this information in its own file and away from the...

Twitter Tip: @username

As I mentioned before, I've recently become wrapped up in the Twitter-craze that is sweeping the web. I'm still a bit of a noob but one think I noticed quickly was some of the Twitter-centric lexicon that was being used by other Twits. Of particular interest is the @username syntax. What does that do? Well as luck would have it the Twitter Help pages have an answer: When someone sends a Twitter that inspires a reply, what can you do? Direct Text the person if your reply is personal and only meant for their eyes.  But sometimes you want everyone...