This error ocurs when you try to register a dll in a windows 7 or windows 2008 OS. This is because these OS uses UAC (user access control) concept. To execute "regsvr32" you have to execute it as a elevated command. To run the tool "regsvr32" follow these steps.
1. Click start.
2. Type "cmd" in the search text box. Command tool appears in the search result.
3. Right click on "CMD" and click "Run as Administrator". A User Account Control dialogue box appears asking you to allow the changes to be done. Click Yes.
4. In the command prompt type "Regsvr32 "dll path\xyz.dll"
1. Click start.
2. Type "cmd" in the search text box. Command tool appears in the search result.
3. Right click on "CMD" and click "Run as Administrator". A User Account Control dialogue box appears asking you to allow the changes to be done. Click Yes.
4. In the command prompt type "Regsvr32 "dll path\xyz.dll"