I am creating a project in vs2010, it is intended to be installed per-user but I need to include a COM object (in a dll, I'm using ATL). The thing is I can only make the DLL register with admin privileges, but my installer doesn't require admin privileges and the com registration fails.
This is what I found: http://blogs.msdn.com/b/jaredpar/archive/2005/05/29/423000.aspx
I did that modifications, changed the .rgs files from HKCR to HKCU, and modified the DllRegisterServer code to override HKCR by HKCU\Software\Classes
But I'm getting the same error: 0x8002801c using regsvr32 (as limited user), and the installer also gives me an error. Is there something else needed to create per-user COM objects?
Thans.
Create manifest file that references DLL. Check out this tool for painless manifest generation
In Visual Studio 2017, you can enable Per-user Redirection option in the project properties > Linker > General.
I didn't need to change modify the rgs file.
To register COM .exe, use /RegServerPerUser flag. The normal /RegServer flag doesn't work for me (link).
To register COM .dll, use regsvr32 /n /i:user "xxxx.dll"
(link).
User contributions licensed under CC BY-SA 3.0