Capture Single Monitor Screenshot on Dual Monitors

When you hit PrintScreen key,  windows will take screenshot on the monitor and copy it to clipboard. But if you have dual monitors setup, you will find screenshot of both monitors are captured. You might wonder how to just capture the single screenshot on the monitor you are working on.

The answer is ALT + PrintScreen. Note that it will take screenshot of the active monitor on your desktop, the one has keyboard/mouse focus.

In addition, you can use CTRL + ALT + PrintScreen to capture the active dialog box or menu on your desktop.

Syspreped Windows 7 fail with “Windows could not finish configuring the system”

After you have installed a Windows 7 or Windows Server 2008 R2, install and configure windows features, install your own app, and then run sysprep command to create an image that is ready to be deployed. When you boot windows for the first time,  it might comes up with following message at the windows setup stage "Setup is starting services" window.

Windows could not finish configuring the system. To attempt to resume configuration, restart the computer.

After you restart the system, you might keep getting the same error.

This is usually caused one of windows features installed or configured not supported by sysprep. The workaround is move the configuration to post setup scripts.

Install Remote Server Administration Tools on Windows 7 SP1

Remote Server Administrator Tools (RSAT) is not compatible with Windows 7 SP1. If you install Remote Server Administration Tools on Windows 7 SP1 slipstreamed media, you will get following error.

The update is not applicable to your computer

That’s because current RSAT version only supports Windows 7 RTM. To workaround this issue, you can Install Remote Server Administration Tools before installing Windows 7 SP1. The SP1 upgrade will update RSAT to SP1 version. The other option is wait for official release of Remote Server Administrator Tools for windows 7 SP1, which will happen this April.

Update 4/8/2011: Microsoft released Windows 7 SP1 RSAT Tools to public today. The download link is here http://www.microsoft.com/downloads/en/details.aspx?FamilyID=7d2f6ad7-656b-4313-a005-4e344e43997d

Remove Earlier Version of Windows boot option

After I upgrade from Windows XP to Windows 7, I see two options at boot up, one is to logon to Earlier Version of Windows, the other is Windows 7. The default option is boot into Windows 7.

There is a workaround to remove the Earlier Version of Windows option from the boot up screen so that it will boot straight into Windows 7 instead of asking users to choose which OS or waiting for 30 seconds and boot into Windows 7.

Continue reading Remove Earlier Version of Windows boot option

Manage Hyper-V remotely from windows 7

Once Hyper-V role is enabled on windows server 2008/R2, Hyper-V manager will be installed automatically. However, you don’t need to log on to Hyper-V host server to use Hyper-V manager. Instead, you can manage Hyper-V machines remotely from you Win7 desktop.

To manage Hyper-V machines remotely from Win 7, following these steps:

  1. Install Remote Server Administration Tools for Windows 7, download here: http://www.microsoft.com/downloads/details.aspx?FamilyID=7d2f6ad7-656b-4313-a005-4e344e43997d&displaylang=en
  2. Go to Start > Control panel Under Programs, click on Get programs
  3. On the left panel, click on Turn Windows feature on or off
  4. On the feature list, expand Remote Server Administration roles > Role Administration Tools, mark Hyper-V Tools, then click OK
  5. Go to Administrative tools > Hyper-V Manager, launch it
  6. Now you can manage Hyper-V virtual machines from your windows 7 box. Continue reading Manage Hyper-V remotely from windows 7

File is Missing or Invalid Error Message

I frequently hit this on my Win7/Vista machines when I run executables that were built from VB6, the following error message appears:

Component ‘filename’ or one o its dependencies not correctly registered: a file is missing or invalid.

The problem is caused by a component or a dependency file used in this executable is not correctly registered or is missing from the system. The solution is copy the file from another computer that does not experience this problem and register it.

I wrote step by step instructions on how to resolve this problem in this post. It uses comdlg32.ocx as example but instructions also apply for other VB6 component file like richtx32.ocx, mscomctl.ocx, tabctl32.ocx and so on

Install Local WordPress Environment on Windows

WordPress is one of most popular blog applications. This application is very easy to use however setup a local environment for theme or plugin development on windows system is not that easy for bloggers. In this post, I will walk thru you how to setup local WordPress environment using Microsoft Web Platform Installer 2.0 with just a few clicks. (I am using 64bit Windows 7 in this tutorial but same steps work windows server 2008 as well)

Continue reading Install Local WordPress Environment on Windows

Register comdlg32.ocx on x64 Win7

Today when I run an old tool on my x64 Windows 7, following error message is displayed:

Component ‘COMDLG32.OCX’ or one of its dependencies is not correctly registered: a file is missing or invalid.

comdlg32.ocx missing error

Here is how to resolve comdlg32.ocx missing error.

  1. Download comdlg32.zip and extract comdlg32.ocx from zip file
  2. Move comdlg32.ocx to c:Windowssystem32 folder. For 64bit Vista/Win7, move comdlg32.ocx to c:WindowsSysWOW64
  3. Open a command line window and run following command:
    regsvr32 c:Windowssystem32comdlg32.ocx

    Note: a) On 64bit Vista/Win7, run this command instead:

    regsvr32 c:WindowsSysWOW64comdlg32.ocx

    b) For Vista/Win7 with UAC turn on, the above command needs to be run from elevated command prompt.

  4. Once comdlg32 is registered successfully, following message will prompt, DllRegisterServer in C:WINDOWSSystem32comdlg32.ocx succeeded.
  5. Now launch the application again you should not see file missing error.

Update: Important note if you use Windows 7: registering comdlg32.ocx must be done as administrator, or regsvr32.exe will fail with error 0x8002801c. To do this as administrator, Go to All Programs -> Accessories -> Command Prompt’, right click on ‘Command Prompt’ icon, and click on ‘Run as administrator’ to start a command prompt, then run the regsvr32 command

Snipping Tool in Vista/Win7

Now windows have snipping tool in Vista and Win7.

You can use Snipping Tool (normally you can find it at %SystemRoot%system32SnippingTool.exe) to capture a screen shot, or snip, of any object on your screen and then annotate, save, or share the image. Simply use a mouse or tablet pen to capture any of the following types of snips:

  • Free-form Snip.  Draw an irregular line, such as a circle or a triangle, around an object.
  • Rectangular Snip.  Draw a precise line by dragging the cursor around an object to form a rectangle.
  • Window Snip.  Select a window, such as a browser window or dialog box, that you want to capture.
  • Full-screen Snip.  Capture the entire screen when you select this type of snip.

After you capture a snip, it’s automatically copied to the mark-up window, where you can annotate, save, or share the snip.

Nice Win7 shortcut key combinations

A list of shortcuts specific to Windows 7

Windows shortcuts

WinKey + Up arrow

Maximize window

WinKey + Down arrow

Restore/Minimize window

WinKey + Left arrow

Snap window to left

WinKey + Right arrow

Snap window to right

WinKey + Shift + Left arrow

Jump window to left monitor

WinKey + Shift + Right arrow

Jump window to right monitor

WinKey + Home

Restore/Minimize all other windows

Taskbar shortcuts

WinKey + T

Preview the first taskbar entry

Press again to move forward through taskbar entries

WinKey + Shift + T

Preview the last taskbar entry

Press again to move back through taskbar entries

(after pressing the keystroke once, use left and right arrow keys to cycle through)

Winkey + # (1-9)

Launches a new instance of the application on the # (1-9) slot on the taskbar

Desktop shortcuts

WinKey + Space

View the desktop

WinKey + G

Bring gadgets to the top of the Z-order

WinKey + P

Opens projection options (Computer Only, Duplicate, Extend and Projector Only)

WinKey + X

Mobility Center

 

Accessibility shortcuts

WinKey + +

Zoom in

WinKey + –

Zoom out

Explorer shortcuts

Alt + P

Show/hide preview pane

Mouse Shortcuts

Shift + Left click on taskbar icon

Open a new instance

Shift + Middle click on taskbar icon

Open a new instance

Ctrl + Shift + Left click on taskbar icon

Open a new instance with admin priveleges

Shift + Right click on taskbar icon

Show window menu (Restore/Minimize/Close, etc)

Shift + Right click on taskbar group

Show window group menu (Restore/Minimize/Close All)

Ctrl + Left click on taskbar icon

Cycle between windows (or tabs) in the group