"I don't think the human race will survive the next 1,000 years, unless we spread into space. There are too many accidents that can befall life on a single planet. But I'm an optimist. We will reach out to the stars."
2012-01-08
I think that title gets a +5 on the geek scale
So, I've tried to do this before with my old HTC HD2 and had mixed results. The problem I had back then was that MyPhoneExplorer would get launched when any USB device was connected, not just the phone. As you can imagine that was a bit annoying. Now I have a shiny new Samsung Galaxy Note I thought it was a good time to take another stab.
What is the goal? I use a free application called MyPhoneExplorer (MPE) to sync Outlook 2010 x32 with my phone. I sync my contacts, calendar, notes, tasks and custom directories. It works really well but you have to connect the phone and then manually load MyPhoneExplorer. That's means loading it from the start menu and then clicking the multi-sync option. How much effort is that?! Ok, not much but it's more than I can be bothered doing each time. The goal is to get MPE to load automatically when the phone is connected, do an automatic multi-sync and then close MPE. Took me like an hour to work it out and searching the depths of the interweb it seems nobody else on the planet has posted how to do this so I felt it would be a nice thing to share.
...
A word of warning, this is a bit tricky and is not recommended for noobs
I'm going to assume you have MPE installed and have it fully working with your phone already. This guide is just covering how to get it to do everything automatically. We are going to use MPE, Windows Task Scheduler and Windows Event Viewer. I'm running Windows 7 but this should work the same with Vista. Not sure about XP. My mini guide for that is UPGRADE YOUR OS ![]()
The first step is to get MPE setup correctly. Load it up and go File->Settings. If it already works then you shouldn't need to alter the "Connection" page. We're only interested in 3 pages "Startup", "Sync" and "Multi-sync". Here is what mine look like:

Tick "Start Minimized" and "Connect on Startup". Untick "Show splash screen" and "Start Multi-sync". The reason we untick "Start Multi-sync" is because we will do this from the command line later on. You can leave it enabled if you want, it's just that I prefer to get straight into the interface if I manually load it instead of waiting for the multi-sync to load. Let's face it. If the auto-sync setup I'm guiding you through works then you probably won't manually load MPE unless you want to change some settings etc. It's just down to personal preference.

Make sure that your Contacts, Calendar and Notes are all set correctly to Outlook 2010. Use the Advanced button next to each of those to pick which address book and calendars to sync.

At this point you should now have MPE syncing with your phone when you load it manually and click "Extras->Start Multi-sync". Any problems with that side of things should be addressed in the MPE forums. We have now reached the bit that caused me all the grief, setting up the Task Scheduler task.
Now you have to become a detective and work out what event is fired when you connect your phone. Open Windows Event Viewer (Control Panel->Administrative Tools->Event Viewer). The event we want to listen for is buried. Here is the path to it:
Event Viewer->Applications and Services Logs->Microsoft->Windows->DriverFrameworks-UserMode->Operational

<QueryList>
<Query Id="0" Path="Microsoft-Windows-DriverFrameworks-UserMode/Operational">
<Select Path="Microsoft-Windows-DriverFrameworks-UserMode/Operational">*[System[Provider[@Name='Microsoft-Windows-DriverFrameworks-UserMode'] and (Level=4 or Level=0) and (EventID=1003)]] and *[UserData[UMDFDriverManagerHostCreateStart[DeviceInstanceId='PUT DEVICE STRING HERE']]]</Select>
</Query>
</QueryList>
Note than when I tested this out and copy and pasted the above the final line was pasted as "< /QueryList>", you need to change that back to "</QueryList>" without the spaces. Change the DeviceInstanceId bit to your XML/HTML encoded string. Remember to wrap it in quotes. Here is what mine looks like:

We are almost done. That was the trickiest part of this guide.
That's it, you are done. If you disconnect and then re-connect your phone again you should see MPE load up, do the multi-sync and then close. Woohoo!