J
Jon Skeet [C# MVP]
I'm trying a very simple program to test the OpenNETCF RAPI/registry
access. Here's the code:
using System;
using OpenNETCF.Desktop.Communication;
public class Test
{
static void Main()
{
using (RAPI rapi = new RAPI())
{
rapi.Connect();
RegistryKey reg = Registry.LocalMachine;
using (RegistryKey key = reg.OpenSubKey("Ident"))
{
string name = (string)key.GetValue("Name");
Console.WriteLine (name);
Console.WriteLine (name.Length);
}
rapi.Disconnect();
}
}
}
(I'm printing the length because I believe there's a bug in the
GetValue code - I suspect it'll return a string which includes a null
at the end.)
Unfortunately, I'm getting the following error:
Unhandled Exception: OpenNETCF.Desktop.Communication.RAPIException:
Unable to create ActiveSync object. Make sure ActiveSync is installed
The specified module could not be found.
Now ActiveSync is definitely installed and running.
A web search shows a couple of other people having the same problem,
but no answers. Any ideas, anyone?
access. Here's the code:
using System;
using OpenNETCF.Desktop.Communication;
public class Test
{
static void Main()
{
using (RAPI rapi = new RAPI())
{
rapi.Connect();
RegistryKey reg = Registry.LocalMachine;
using (RegistryKey key = reg.OpenSubKey("Ident"))
{
string name = (string)key.GetValue("Name");
Console.WriteLine (name);
Console.WriteLine (name.Length);
}
rapi.Disconnect();
}
}
}
(I'm printing the length because I believe there's a bug in the
GetValue code - I suspect it'll return a string which includes a null
at the end.)
Unfortunately, I'm getting the following error:
Unhandled Exception: OpenNETCF.Desktop.Communication.RAPIException:
Unable to create ActiveSync object. Make sure ActiveSync is installed
The specified module could not be found.
Now ActiveSync is definitely installed and running.
A web search shows a couple of other people having the same problem,
but no answers. Any ideas, anyone?