PDA

View Full Version : Registry settings not copied correctly



Brian
07-11-2016, 05:59 PM
Starting last week, MapPoint 2011 began popping up this error when opening: "Your registry settings for this application were not copied correctly. To correct these settings, run Setup again for this application from the location where you originally installed it." (Well, that is the error when opening it directly; the error when opening from my VBA application is a lot less transparent. More on that below...)



This is Windows 10 Home 32-bit, upgraded from Windows 7 Home 32-bit long before this problem began. While I consider that upgrade to be a mistake, given the problems of older computers upgrading to Windows 10, the problem appeared far too long after that upgrade (about two months) to simply blame the Windows 10 upgrade (much as I would like to do that!). So I highly suspect some Windows update, but the unique combination of Windows 10 and MP 2011 is not one where I am likely to trace down the specific update that caused the problem. And, Windows 10 being what it is, my chance of getting rid of an update if that is, indeed, the problem is probably just about 0%.

On the other hand, the user indicated there was a power outage somewhere around the time of the problem, so my next theory was that this had corrupted some file(s) and/or registry setting(s). However, I then effectively ruled that out by a full uninstallation of MP2010, reboot, removal of the relevant MapPoint folders in Program Files, ProgramData, and user's AppData folder, relatively thorough manual removal of relevant (MapPoint-related) registry keys/values in both HKCU and HKLM, then another reboot and reinstallion--all to no avail.

Just a bit of trial-and-error then led to discovery of the fact that if I right-click the MapPoint shortcut on the desktop, then Run as Administrator, it runs fine. So I know this is rights-related, even though the current useris the only user and is a system administrator. So the next obvious step on my journey toward a solution was to disable UAC, which is known to involve itself in some issues like this, particularly for older applications. But that changed nothing.


So I went into the MapPoint shortcut on the desktop → Properties → Compatibility (tab) → Change Settings for all Users (button) → Run this program as an administrator (checkbox). Success--as far as it goes. Now I can at least open MapPoint without it being blocked by the "registry settings not copied" message.


So far, so good, I suppose. But now enter the real complication: I have a VBA application that connects to a MySQL database, pulls address data out, sends it to MapPoint, allows the user to group addresses, optimize stops (automatically via the Optimize method and/or manually on the map, one-by-one) then, after the user as re-ordered the stops, pulls the new stop order back into the database. This is completely unaffected by the shortcut setup above, which applies only when opening MapPoint directly from its own .lnk file.


To digress just a bit: I am just the developer of this application that connects/uses MapPoint via its API. I do not provide general IT support to this client. So, despite the possibility that this could indicate some other corruption in the current user's profile (as has been suggested in several self-fix-it links I have seen on this issue), I am not really in a position to become involved enough to drop & re-create the user's local profile. There is too much time involved and risk of data loss on a system that I do not support on a daily basis.


So another visit with the resident geek inside my head tells me to create a shortcut like that above, but to MSAccess (since my VBA application is actually built in MSAccess), with my specific application as an argument--and then set compatibility to run as an administrator the same as I did for the MapPoint shortcut above. That looks like this:


C:\Program Files\Microsoft Office\Office14\MSACCESS.EXE" C:\Users\[Current user ID]\Desktop\[Name of my Access/VBA app].accde


OK, so that works. It opens Access in elevated admin mode and then calls my application. So there is no error now when Access opens MapPoint. But what a workaround! And it is very specific to the location of the Access EXE as well as the location of my application.


I know there is a local security policy settings to make all administrators equal ("Run all administrators in Admin Approval Mode"). But Windows 10 Home has no secpol.msc or gpedit.msc where I can make that change through the GUI, so I may next look at manually changing the relevant EnableLUA registry value to see if that is a blanket solution. I am pretty sure that will solve the problem. Yes, yes--I understand the potential security risk, but really want to know if this is at least a more permanent workaround than a highly-tweaked shortcut.


On the other hand, I figure maybe someone here has some two-minute fix for all of this. If not, at least some other poor soul reading this can perhaps implement what I have found/developed this far.