Thursday, September 25, 2008

Printing Long DIVs

I encountered a problem recently where printing a page with Internet Explorer caused a page break before the main content, chopped the content off after the 2nd page of the printout and then printed a blank page. So the users would get 3 pages, a page with the header, a page with the top part of the content and a blank page.

The issue turned out to be caused by a DIV that was being styled as overflow:auto that contained a long table. The table had recently increased in size so it now spanned two pages.

To fix it, all I needed to do was set the DIV's overflow style to visible in the page's print stylesheet.

overflow: visible !important;

Saturday, August 23, 2008

Superdense Computers

Cool article by Hans Moravec from 1986 on building computers and other technology from neutronium, magnetic monopoles and Higgsinium. It's slightly out of date since the theory that allowed for Higgsinium has changed but it's still interesting.

Superdense Computers

Friday, August 01, 2008

DebuggerStepThroughAttribute

The DebuggerStepThroughAttribute sounds like it could be useful.

Pedram Rezaei's Ramblings : .NET debugging made easier: "As far as the CLR is concerned, there is no semantic attached to this attribute. However Visual Studio does not step through methods or classes that are decorated with this attribute"

You can use it to skip over stuff you don't need to step through while debugging but you can still set breakpoints in the code if you uncheck "Enable Just My Code (Managed only)" under Tools | Options | Debugging | General.

Tuesday, July 29, 2008

Accelerator keys you should avoid for Asp.Net 2.0 controls

The list of accelerator keys that are already used by the browser.

Accelerator keys you should avoid for Asp.Net 2.0 controls:
"ALT + F
ALT + E
ALT + V
ALT + I
ALT + O
ALT + T
ALT + A
ALT + W
ALT + H"

Thursday, July 24, 2008

SwapMouseButtons

This is a pretty cool tool.

SwapMouseButtons - Freeware: "An easy way to share a computer between left-handed and right-handed persons"

I'm ambidextrous so it lets me easily swap the mouse to whichever hand is most convenient.

Monday, July 14, 2008

LINQ: Building an IQueryable Provider

The Wayward WebLog : LINQ: Building an IQueryable Provider - Part X: "find a nice shady tree, relax and meditate on why your world is so confused and full of meaningless tasks that it has kept you from pursuing the perfection of writing IQueryable providers"

Friday, July 11, 2008

.NET Developers’ Reference Cards

This guy has compiled a list of developer's reference cards / cheat sheets for .NET developers.

.NET Developers’ Reference Card Roundup | Alvin Ashcraft's Morning Dew

Making PowerShell Start Faster

Windows PowerShell : Update-Gac.ps1: "people run this script long after their install and things get a TON faster"

Wednesday, July 02, 2008

Visual Studio 2008 Keybinding Posters

Charlie Calvert's Community Blog : Where are the Visual Studio 2008 Keybinding Posters?

He's got links to the Visual Studio 2008 keybinding posters and to the C# keybindings as a spreadsheet.

Tuesday, July 01, 2008

Sunblock

I'd been wondering why my sunblock didn't seem to work as well as it used to. This site did product comparisons on sunscreens and most of them don't work well.

Cosmetic Safety Database - Sunscreens: "Does your sunscreen work? An investigation of nearly 1,000 brand-name sunscreen products finds that 4 out of 5 contain chemicals that may pose health hazards or don't adequately protect skin from the sun's damaging rays. Some of the worst offenders are leading brands..."

Monday, June 30, 2008

Auto-Formatting Removes Tabs

Turns out there's a way to get Visual Studio 2008 to preserve your spacing if you've lined up your declaration statements.

Karen's Space : Auto-Formatting Removes Tabs: "A new option was added to Tools | Options | Text Editor | C# | Formatting | Spacing | Set other spacing options.
The option is a check-box and says: “Ignore spaces in declaration statements”."

Saturday, June 28, 2008

Regular Expressions

Jeff Atwood's got a post on regular expressions that included some info on the IgnorePatternWhitespace option which I'd been unaware of till now. That looks like it could be useful.

The comments on his post led to the Regular Expressions Cheat Sheet and to Roy Osherove's Regulazy and Regulator tools. I've used the Regulator in the past but haven't tried Regulazy yet. May want to look into it the next time I'm building a regular expression.

Thursday, May 29, 2008

Sysinternals

BetaNews | Russinovich's Windows toolkit goes live, quite literally: "Admins now have immediate access to any of Sysinternals utilities from any Windows computer, without having to install anything first."

live.sysinternals.com

Monday, May 26, 2008

Golden Tortoise Beetle

Found an interesting looking beetle in my house last night that looked like a drop of gold. When I handled it to get a better look and move it outside, it's color changed a bit to more greenish and transparent so I could see a lady bug like pattern under it's shell. I did a bit of web searching today and it turns out it was a Golden Tortoise Beetle.
The golden tortoise beetle, Charidotella sexpunctata bicolor (Fabricius), is brilliant brassy or greenish-gold in life. When disturbed, the color becomes orange with black spots.

Golden Tortoise Beetle from Bug Guide

Golden Beetle from Lady Bug Lady

Golden Tortoise Beetle from Bug of the Month

Golden Tortoise Beetle images from Google

Tuesday, May 20, 2008

Cool Text: Logo and Graphics Generator

Cool Text: "is a free graphics generator for web pages and anywhere else you need an impressive logo without a lot of design work"

Saturday, May 17, 2008

HighlightCurrentLineInEditor

Here's a Visual Studio DXCore plugin that might be useful.

Rory's Ramblings: New Plugin HighlightCurrentLineInEditor: "a new plugin called 'HighlightCurrentLineInEditor' which unsurprisingly highlights the current active line in the editor in a nice shade of blue"

Friday, April 11, 2008

Coding Productivity Macro

Kirill Osenkov : Coding productivity: macros, shortcuts and snippets

This macro by Kirill Osenkov inserts a pair of curly braces and places the cursor inside them. It's useful when mapped to Shift+Enter.


Sub InsertCurlies()
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text =
"{"
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text =
"}"
    DTE.ActiveDocument.Selection.LineUp()
    DTE.ActiveDocument.Selection.NewLine()
End Sub

Tuesday, April 08, 2008

Robocopy GUI

Robocopy GUI: "allows users to customize their Robocopy scripts using a simple and very familiar-looking graphical interface"

Wednesday, March 26, 2008

Add Using Statement in Visual Studio 2008

Add Using Statement in Visual Studio 2008: "In Visual Studio 2008, if you've just added a class for which you haven't yet added the corresponding using statement to bring the namespace into scope, you can hit control-dot"

Sunday, February 24, 2008

Graphics Programming Black Book

Michael Abrash's Graphics Programming Black Book can be downloaded from BYTE.com.

Graphics Programming Black Book by Michael Abrash : "Michael Abrash's classic Graphics Programming Black Book is a compilation of Michael's writings on assembly language and graphics programming (including from his "Graphics Programming" column in Dr. Dobb's Journal). Much of the focus of this book is on profiling and code testing, as well as performance optimization. It also explores much of the technology behind the Doom and Quake 3-D games, and 3-D graphics problems such as texture mapping, hidden surface removal, and the like."

Sunday, February 17, 2008

Checking User Logins on a Remote Server

Needed to check the logged in users on a server recently and couldn't remember the QWINSTA (Query WINdows STAtion) command or find my previous post about it so I figured I'd do another post on the issue and include the words I searched for when I didn't find it.

Managing Terminal Services Session Remotely: "Windows 2000+ (includes Windows XP and 2003) have two command-line tools called qwinsta and rwinsta that can query and reset a remote session."

The Query Session command is the replacement for qwinsta on Windows Server 2008.

Wednesday, February 13, 2008

Fractal Desktops

Fractal Desktops: "Mandelbrot set images for the desktop."

Celebration from their Best of 2004 collection is one of my favorites.

Saturday, January 12, 2008

Free File Difference and Merge Tools

DiffMerge from SourceGear
WinMerge which is Open Source