hi guys, i want to read windows mobile registry from windows application, the device is connected via activesync.
any ideas?

Dani AI

Generated

A concise follow-up to and : there are two practical ways to read a Windows Mobile/CE registry from a PC over ActiveSync — call the device (helper) app, or call the device remotely using RAPI. ' "call the demo app" idea is valid and often the simplest when SDK linking or device security is a problem; the alternative below shows the direct-RAPI approach so a Windows app can read values from the device registry.

To read the device registry directly from a PC process use Microsoft RAPI (Remote API). Typical steps: install the Windows Mobile/CE SDK that matches the device so you have rapi.h/rapi.lib; build the desktop app as 32-bit (x86) to link the SDK libs; initialize RAPI from the PC, open the device key (HKEY_LOCAL_MACHINE or HKEY_CURRENT_USER) with CeRegOpenKeyEx, read values with CeRegQueryValueEx (or equivalent), close and then uninitialize RAPI. Make sure ActiveSync or Windows Mobile Device Center is running and the device is unlocked — many ROMs block RAPI when security is enforced.

If linking RAPI is undesirable, implement a tiny device-side helper (what suggested): have the helper read registry values and write them to a file or serve them over a small socket/HTTP endpoint; copy or execute that helper from the PC and read its output. For C# projects the common shortcut is to use a managed RAPI wrapper (for example OpenNETCF's desktop communication libraries) to avoid low-level P/Invoke. Troubleshooting notes: ensure matching SDK/device versions, target x86, check ActiveSync/WMDM is connected, and remember some devices/ROMs disable remote registry access for security.

Recommended Answers

All 3 Replies

this example works on pocket pc, i want the same thing to run in pc.

Let your windows application call the demo application. work around it.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.