About Me · Send mail to the author(s) E-mail · Twitter

At GROSSWEBER we practice what we preach. We offer trainings for modern software technologies like Behavior Driven Development, Clean Code and Git. Our staff is fluent in a variety of languages, including English.

Feed Icon


Open Source Projects


Blogs of friends

Now playing [?]

Error retrieving information from external service.


Previous Page Page 2 of 8 in the ToolsAndSoftware category Next Page

Comparing and Synchronizing Subversion Folders With Total Commander

Posted in Tools and Software at Monday, 12 March 2007 01:58 W. Europe Standard Time

My Swiss Army knife for file operations is Windows Explorer. No, just kidding. In fact, I don't see a point in using Windows Explorer at all. It always feels like an insurmountable hassle to get this tool doing what I want quickly. (Yes, I know about Ctrl+A, Ctrl+C, Ctrl+V and their siblings.)

Anyway, I didn't want to bash Microsoft's premier file manager, instead I wanted to share a little goodie for Total Commander, a tool that deserves to be called Swiss Army knife. Total Commander is my tool of choice when it comes to doing anything with files. It's runs virtually all the time I'm in front of the computer. There's also a version for your USB stick and one for Windows Mobile and craploads of plugins to try out.

Total Commander comes with a powerful synchronization tool that allows you to compare and synchronize two directories. Because Total Commander handles zip files transparently, it allows to synchronize between a zip and a directory or between two zip files. Comparison features I've almost always enabled are the "Subdirs", "By content" and "Ignore date" checkboxes. This allows me to quickly see any differences between folders.

Synchronize Directories

If a folder contains .svn or _svn subfolders to accommodate Subversion's internal bookkeeping files, Total Commander will also compare these files. Of course this is pretty useless since these files will most likely not hold information you're interested in. The Synchronize Directories dialog provides a filter text box at the top that allows you to define a pattern for files to include and ignore in the search. The syntax is simple but the tiny input field doesn't assist you defining a filter, at least it remembers the last filters used.

Here's a filter definition leaving out all files related to Subversion, it came in handy a couple of times for me.

*.*|*.svn-base all-wcprops entries format dir-prop-base

Now Playing [?]: MetricLive it out – Monster hospital

RDP/Terminal Services Port Configurator for Windows Mobile

Posted in Mobility | Tools and Software at Thursday, 10 August 2006 21:11 W. Europe Daylight Time

Remote DesktopWindows Mobile devices come with an integrated Terminal Services client (also known as Remote Desktop Protocol, RDP). This client allows you to connect to any Remote Desktop-enabled machine like Windows XP Professional, Windows Server and Linux (another here). Actually a tempting idea to connect to your home machine if you're abroad. You just need a some kind of internet connection.

The Network

If there are multiple machines in a firewalled network the only public IP address known on the internet is the one of the router. The default server port for RDP connections is port 3389 (TCP protocol). RDP clients use this port when connecting to a RDP server. What happens if an internet user (RDP client) connects to port 3389 on the public IP of the router? If the firewall is set up correctly, nothing, i.e. the connection is refused. To enable Remote Desktop connections the network administrator has to configure a port mapping. The port mapping basically tells the firewall to open a specific port and route all data from this port to a specific machine on the internal network (for example your Windows XP box). If two users want to expose their machines to the internet the administrator has to open two ports, because a single port is always attached to a single internal machine. See the illustration below for a general overview.

Port Mappings

The Failure of the Windows Mobile RDP Client

To connect to the first machine ("Your Computer") from the internet the user has to tell its RDP client to simply connect to the firewall (because it's the machine with the public IP address). Because 3389 is the default port this actually translates to ServerName:3389, where ":" delimits the server name from the port number. To connect to "Another Computer" the address is ServerName:3390.

This is where the RDP client of Windows Mobile fails. It just won't accept servers with appended port numbers.

RDP Invalid Server Name

The First Approach

It's actually possible to change the behavior of the Remote Desktop client to connect to non-standard ports like 3390 or any other by applying a registry hack.

  1. Open the device registry using a registry editor
  2. Open the key HKEY_CURRENT_USER\Software\Microsoft\Terminal Server Client\Default\
  3. Create an entry of type DWORD, called Server Port
  4. Set the value to the required port number (3390 in the case above)

My Solution

It's actually a very cumbersome task to edit the registry, especially if you're changing port numbers fairly often because you need to connect to different machines. After proof-reading Torsten's book on Windows Mobile development I thought this would be an easy to automate task.

I've written a little helper application that sets the registry values for you. I've tested it on my Axim x51v and inside the emulators of Visual Studio 2005. It's a .NET Compact Framework 1.0 application so you most likely don't have to install the .NET runtime on Windows Mobile 5.0 devices.

RDP Port Switcher

DownloadDownload the RDP Port Switcher Setup CAB. Feel free to add your own functionality, source code is available.

Now playing: Big Bud - Late Night Blues - State of mind

DirectUpdate and Windows Security Policy

Posted in Tools and Software | Networking at Saturday, 05 August 2006 14:32 W. Europe Daylight Time

We are working with a DSL connection here and offer some services to the outside world, for example Remote Desktop login to each roommate's workstation. This web site is also served through this DSL connection. That's what Bill Gates must have meant when he talked about the vision of "information on your fingertips"¹.

Simple consumer DSL line like ours have an annoying "feature": The provider disconnects the line every 24 hours to force redialing the connection and thus allowing him to assign a new public IP address. This prevents offering large scale services and forces businesses to buy a more expensive connection package with static public IPs. Because nobody on the internet knowns our current IP address (as it changes every day) we use a Dynamic DNS service to update the IP addresses of our domains ( and some others).

There are Dynamic DNS clients that monitor the connection and issue an IP update to Dynamic DNS service like DynDNS. Current routers even come with such a client. I was trying the demo version of DirectUpdate to see how it works.


This is the DirectUpdate management screen. Notice that the window is not resizable by means of the standard minimize, maximize and restore buttons (Minimize, Maximize and Restore Buttons). What happens if you log in with a resolution of 640x480 and the window floats around off-screen? You're lost. One might say that this a very uncommon case today as CRTs with this resolution are pretty much dead, but we had such a display connected to the old server.

After installing DirectUpdate everything worked fine, DynDNS updates were issued and the service ran reliably. However, the security event log filled up with strange "Audit Policy Change" events. These events occurred at random times. Each time the Logon/Logoff and Account Logon audit, which forces Windows to log successful and failed logon attempts to the security event log, was completely disabled. All other audit settings remained untouched.

Event ID: 612
Audit Policy Change:
New Policy:
Success Failure
  -  - Logon/Logoff
  -  - Object Access
  -  - Privilege Use
  -  - Account Management
  -  - Policy Change
  -  + System
  -  - Detailed Tracking
  -  - Directory Service Access
  -  - Account Logon
Changed By:
User Name: ARWEN$
Domain Name: WG
Logon ID: (0x0,0x3E7)

I've reset the Windows Audit Policy to log Logon/Logoff and Account Logon events each time a 612 event was logged but after some hours the policy change would occur again. Tracing the system events using Filemon, Regmon and Process Explorer gave no clue about the source of the error. Time to open a support case using a voucher that Torsten kindly let me use.

The Microsoft support clerk recommended disabling all non-Microsoft services (there were about four) on the system. Lo and behold, the Audit Policy Change events didn't appear again. After gradually re-enabling these services I found that DirectUpdate was the source of the policy changes. The next step was to prevent DirectUpdate from issuing policy change requests. As there's no setting on the UI regarding policy, I had to dig deeper.

DirectUpdate installs as a Windows service. Because it appears easier for the developers if DirectUpdate the service runs under the SYSTEM account, the most powerful account in Windows that's allowed to perform every operation. Why should a service that's sole purpose is to monitor IPs and sending HTTP requests run in such an unrestricted environment? I changed the service to run under the Network Service account, a restricted user for the very purpose of running services under it:

The new Network Service account [...] has a greatly reduced privilege level on the server itself and, therefore, does not have local administrator privileges.
  1. Open the Services MMC Snap-In by running services.msc
  2. Search for the "DirectUpdate engine" service
  3. Right-click, select Properties and open the Logon tab
  4. Enable the This account radio button, then Browse and enter NetworkService or browse for the localized Network Service name
    DirectUpdate Logon Settings
  5. Click OK
  6. Grant the following rights to the Network Service account
    • Change in the DirectUpdate log file folder
    • Change in C:\Program Files\DirectUpdate\Dump\
  7. Restart the service

This did the trick. DirectUpdate runs peacefully and the Security Policy doesn't get changed anymore. So, thanks again Torsten for allowing me to contact Microsoft Support on the issue!

¹ Phew, this is the ugliest Microsoft site I've ever seen.

Now playing: Yonderboi - Splendid Isolation - Motor

Windows CE Plug-In for Total Commander

Posted in Mobility | Tools and Software at Thursday, 03 August 2006 01:15 W. Europe Daylight Time

Today I was checking the list of plug-ins for my favorite Windows Explorer replacement Total Commander. There I found the WinCE file system plug-in (direct download) which plays perfectly with my Dell Axim x51v. No need to launch Explorer just to copy my podcasts to the device. It's been a pain in the neck, especially the inconsistent handling of double-clicks on the device folders: Sometimes a new Explorer window would open for no obvious reason.

The SymbFS plug-in for my Nokia phone didn't work so well, but this is maybe due the its beta state and that development ended in late 2004. If you're a Total Commander user you should definitely take a look on the other plug-ins like Events NT, Registry, ProcFS, Services and WebDAV.

BTW, Dell released firmware update A04 (German version) for the Axim x51v. This release should provide "enhanced CF I/O card performance". Several forum entries state that the update has resolved the disappearing CF card problem. I've updated my device last weekend and didn't have any problems so far.

Update: The NokiaFS plug-in works fine with my Nokia 6680.

Now playing: Aural Float - Freefloat - Soulsearching Add-In for Visual Studio 2005

Posted in Tools and Software | Visual Studio at Monday, 24 July 2006 18:38 W. Europe Daylight Time LogoThe .NET Framework 2.0 has become pretty comprehensive compared to version 1.1. For example, Microsoft added features for ACLs in .NET 2.0. However, in some cases us developers need a function not directly supported by the framework but by the underlying (Windows) operating system. Platform Invoke, or P/Invoke for short, is a way to call Windows functions from .NET code. First you'll have to declare the function by finding out which DLL contains the function and the type of return value and parameters. When you have to do this more than twice a day, this can become nerve-racking.

We live in a world of social software and Adam Nathan had the great idea of creating the Wiki for the reason that nobody should be bothered with the tasks browsing MSDN for finding the correct DLL and translate the built-in Windows types to their .NET representation ...well, except the first one that uses a platform function :-) The Wiki is a great resource for P/Invoke declarations for a wide variety of libraries and everyone is invited to post his own.

To make the Wiki even more useful, Adam Nathan developed the Add-In for Visual Studio .NET 2003. I like it a lot and wondered why it hasn't been ported to Visual Studio 2005 for a long time. Bernhard Elbl finally created a version for Visual Studio 2005 in May, and yesterday I fortunately stumbled across it!

However, I had a hard time installing it because I run an English version of Visual Studio 2005 on a German Windows XP. Visual Studio searches for Add-Ins in pre-defined folders that are not localized to the OS language. You find these paths under Tools/Options/Environment/Add-In/Macros Security in Visual Studio 2005.

Visual Studio Add-In Options

As you see the first entry reads

%ALLUSERSPROFILE%\Application Data\Microsoft\MSEnvShared\Addins

On a German machine this should rather be


You can either add a path containing your localized version of "Application Data" or move the file to a folder that is contained in the search folder list.

Happy P/Invoking!

Now playing: Madonna - Confessions on a dance floor - Jump

Previous Page Page 2 of 8 in the ToolsAndSoftware category Next Page