Menneisyys
02-18-2006, 07:12 PM
You may already have noticed that the built-in mailer client in Windows Mobile, Messaging (was also known as (Pocket) Inbox in pre-Windows Mobile 2003SE operating systems) automatically synchronizes the contents of the active POP3/IMAP mailbox with your last-used POP3/IMAP Messaging mailbox when you cradle/dock your Pocket PC.
This, in cases, may lead to unwanted consequences. Many POP3/IMAP servers prohibit multiple, parallel connections to the same mailbox. With servers like these, you'll always run into access problems if you try to access your mailboxes from your, say, desktop mailer client, while your PDA is cradled.
The reason for this is very simple. As has been pointed out, when you cradle your Pocket PC, Messaging is invoked and it automatically synchronizes the contents of the last-used mailbox, keeping the connection open (that is, it doesn't log out of the mail server when it's done fetching mail).
The connection being kept open results in other clients' inability to log into the same mailbox while the PDA is cradled. Unfortunately, the error messages you'll receive in cases like this can be rather cryptic and help little in tracking down the problem; this is why so many Pocket PC users are suffering from the problem and posting questions about it to Pocket PC boards.
What's the solution?
Before cradling the PDA, I used to make sure the selected, active Messaging account is not the one(s) that prohibit(s) multi log-ins. This made it possible to continue accessing even my single-login mailboxes on my desktop PC, even with my PDA docked and synchronized.
Of course, this solution is pretty awkward as you will end up having to change your account every time before cradling your PPC. This is why I've continued investigating the file system, the WinCE databases and, finally, the Registry to find out what causes Messaging to be auto-invoked upon docking and how you can combat this.
The solution is, fortunately, very easy. Read on!
Get a registry editor (look around here (http://www.pocketpcmag.com/blogs/menneisyys/UltimateRoundupOfRegistryEditors.asp) if you need to choose one) and navigate to the registry key \HKEY_LOCAL_MACHINE\ SOFTWARE\ Microsoft\Shell\Event\ Dock\Inbox:
http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground.bmp.png
Tap and hold the value named command in the above key and choose Rename from the context menu:
http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground-2.bmp.png
Give the value another name (it can be anything); say, dummycommand.
http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground-3.bmp.png
Alternatvely, you can also entirely remove this value – or, for that matter, the entire Inbox key. Then, however, you will have a harder time to set it back if you still need the auto-synchronization functionality (unless you export the key before deleting it and just reimport it later when needed).
Remember not to touch the contents of 'command' to refer to a non-existing file because, then, you'll get an error message every time you cradle your PDA, as can be seen in this screenshot (http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground-4.bmp.png) (taken on a WM5 x51v, after renaming tmail.exe to atmail.exe).
For techies: how did I find this out?
First, I've checked whether it's \Windows\Startup\poutlook.lnk that keeps Messaging running in the background and looking for the synchronization to start. After removing the above autostart link file and restarting my test PDA's, the problem remained, showing something other was the problem.
Then, I turned to the DB_notify_events WinCE database, which notifies applications on certain system events like being switched on/connected to the outside world via a serial connection and is a cause for a lot of problems (http://www.pocketpcthoughts.com/forums/viewtopic.php?t=36471). There were no signs of tmail.exe (the executable for Messaging/Pocket Inbox) in here, as can be seen in this screenshot (http://www.winmobiletech.com/kuvat/DontLetInboxSync-dbView.bmp.png) (taken using the excellent dbView (http://www.pocketpcfreewares.com/en/index.php?soft=152) application).
I didn't give up and continued researching. Knowing that the Windows Mobile OS, as with the DB_notify_events WinCE database, in most cases, requires the use of the executable file name top operate, I've also scrutinized the Registry for the executable name of Messaging – that is, tmail.exe. And yes, I've found something - I found out that the Windows Mobile operating system also keeps a separate registry key for applications to be invoked on the PDA being cradled/docked. It's \HKEY_LOCAL_MACHINE\SOFTWARE\ Microsoft\Shell\Event\Dock\.
Here, there may be any number of subkeys; by default, there is only one, Inbox. These subkeys must contain a value named 'command' that contains the name of the program (and the optional parameters to pass to it) to run in order to operate; if the value command is missing, nothing happens.
This, in cases, may lead to unwanted consequences. Many POP3/IMAP servers prohibit multiple, parallel connections to the same mailbox. With servers like these, you'll always run into access problems if you try to access your mailboxes from your, say, desktop mailer client, while your PDA is cradled.
The reason for this is very simple. As has been pointed out, when you cradle your Pocket PC, Messaging is invoked and it automatically synchronizes the contents of the last-used mailbox, keeping the connection open (that is, it doesn't log out of the mail server when it's done fetching mail).
The connection being kept open results in other clients' inability to log into the same mailbox while the PDA is cradled. Unfortunately, the error messages you'll receive in cases like this can be rather cryptic and help little in tracking down the problem; this is why so many Pocket PC users are suffering from the problem and posting questions about it to Pocket PC boards.
What's the solution?
Before cradling the PDA, I used to make sure the selected, active Messaging account is not the one(s) that prohibit(s) multi log-ins. This made it possible to continue accessing even my single-login mailboxes on my desktop PC, even with my PDA docked and synchronized.
Of course, this solution is pretty awkward as you will end up having to change your account every time before cradling your PPC. This is why I've continued investigating the file system, the WinCE databases and, finally, the Registry to find out what causes Messaging to be auto-invoked upon docking and how you can combat this.
The solution is, fortunately, very easy. Read on!
Get a registry editor (look around here (http://www.pocketpcmag.com/blogs/menneisyys/UltimateRoundupOfRegistryEditors.asp) if you need to choose one) and navigate to the registry key \HKEY_LOCAL_MACHINE\ SOFTWARE\ Microsoft\Shell\Event\ Dock\Inbox:
http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground.bmp.png
Tap and hold the value named command in the above key and choose Rename from the context menu:
http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground-2.bmp.png
Give the value another name (it can be anything); say, dummycommand.
http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground-3.bmp.png
Alternatvely, you can also entirely remove this value – or, for that matter, the entire Inbox key. Then, however, you will have a harder time to set it back if you still need the auto-synchronization functionality (unless you export the key before deleting it and just reimport it later when needed).
Remember not to touch the contents of 'command' to refer to a non-existing file because, then, you'll get an error message every time you cradle your PDA, as can be seen in this screenshot (http://www.winmobiletech.com/kuvat/DontLetInboxSyncInBackground-4.bmp.png) (taken on a WM5 x51v, after renaming tmail.exe to atmail.exe).
For techies: how did I find this out?
First, I've checked whether it's \Windows\Startup\poutlook.lnk that keeps Messaging running in the background and looking for the synchronization to start. After removing the above autostart link file and restarting my test PDA's, the problem remained, showing something other was the problem.
Then, I turned to the DB_notify_events WinCE database, which notifies applications on certain system events like being switched on/connected to the outside world via a serial connection and is a cause for a lot of problems (http://www.pocketpcthoughts.com/forums/viewtopic.php?t=36471). There were no signs of tmail.exe (the executable for Messaging/Pocket Inbox) in here, as can be seen in this screenshot (http://www.winmobiletech.com/kuvat/DontLetInboxSync-dbView.bmp.png) (taken using the excellent dbView (http://www.pocketpcfreewares.com/en/index.php?soft=152) application).
I didn't give up and continued researching. Knowing that the Windows Mobile OS, as with the DB_notify_events WinCE database, in most cases, requires the use of the executable file name top operate, I've also scrutinized the Registry for the executable name of Messaging – that is, tmail.exe. And yes, I've found something - I found out that the Windows Mobile operating system also keeps a separate registry key for applications to be invoked on the PDA being cradled/docked. It's \HKEY_LOCAL_MACHINE\SOFTWARE\ Microsoft\Shell\Event\Dock\.
Here, there may be any number of subkeys; by default, there is only one, Inbox. These subkeys must contain a value named 'command' that contains the name of the program (and the optional parameters to pass to it) to run in order to operate; if the value command is missing, nothing happens.