I find 16-bit color desktops cause me more eyestrain than 32-bit, so I wanted my Windows Server 2008 remote desktops in all their 32-bit glory. By default, they are limited to 16-bit but this is easily remedied. Go to Start > Administrative Tools > Terminal Services Configuration (or Start > Run > tsconfig.msc), right-click the connection under Connections and select Properties, and select the Client Settings tab. Color Depth probably has Limit Maximum Color Depth checked and 16 bits per pixel in the dropdown. Uncheck it, or change the dropdown to 32 bits per pixel. Click OK and you’ll likely get a dialog about how this won’t change the current session. So close that and log off and back on, making sure your client is set to use 32 bits. You should now have a 32-bit display depth and a little less eyestrain.
Categories: Windows Server 2008
Unfortunately, I still have the occasional need to write a batch file that has to run on generic XP. And on such occassions, sometimes I want the script – if we can call it that – to wait for a couple of seconds at some point. Alas, XP has no sleep or similar command, but there is a way to simulate the functionality. I found the gist of this idea at Rob van der Woude’s Scripting Pages, and truth be told cannot believe I had never seen or thought of this before. The core idea is to use a number of ping commands to localhost.
So for example, I wanted to kill some Documentum Desktop processes that integrate with the explorer.exe task that makes up the Windows desktop interface. But, I wanted it to pause for a moment before relaunching explorer; ping to the rescue. Here is the batch file I ended up creating for the purpose.
@echo off
rem
rem Kills core Documentum Desktop processes and restarts Explorer so they relaunch
rem
taskkill /f /im dcathmgr.exe /im dcevtsrv.exe /im explorer.exe
rem tasklist /nh |sort
rem --- the next line just delays for a moment
ping -n 3 localhost >nul
start explorer.exe
The second-to-last line simply pings localhost 3 times, buying a couple of seconds of delay. You can adjust the number of times upward if you want it to wait a little longer. Normally the pings will be separated by a second, but the last attempt will terminate the ping command line so you really want number of seconds + 1, e.g. -n 6 would wait about 5 seconds.
And that’s all I have to say about that.
Categories: Microsoft Windows