Please help me to solve the following problem:
After win10 update Red Stone 4 the following code sequence stops working:
- RasPhoneBook pbk = GetUserPhoneBook();
- RasEntry entry = RasEntry.CreateVpnEntry(ConnectionName, server, this.VpnStrategy, RasDevice.GetDeviceByName(this.DeviceName, RasDeviceType.Vpn));
- pbk.Entries.Add(entry);
the error occurs at the third line 3. pbk.Entries.Add(entry);
The error message is: An incorrect structure size was detected.
and the StakTrace is
at DotRas.Internal.ThrowHelper.ThrowRasException(Int32 errorCode) at DotRas.Internal.RasHelper.SetEntryProperties(RasPhoneBook phoneBook, RasEntry value) at DotRas.RasEntryCollection.InsertItem(Int32 index, RasEntry item) at DotRas.Design.RasCollection`1.Add(TObject item)
Thank you