Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Can't run regsvr32 from .bat file, but can run from CMD

11 Apr 2013   #21
Kaktussoft

Microsoft Community Contributor Award Recipient

Microsoft Windows 7 Home Premium 64-bits 7601 Multiprocessor Free Service Pack 1
 
 

regsvr32 ole32.dll
regsvr32 /s ole32.dll
pause


Both commands work in elevated command prompt?
Both command work in bat file (run it elevated)?


My System SpecsSystem Spec
.
11 Apr 2013   #22
jamesaru

Windows 7 Pro 64-bit
 
 

Quote   Quote: Originally Posted by UsernameIssues View Post
Do you have UAC turned off?
Are you on an admin account or on the Administrator (built in) account?
When I installed Windows (from the Lenovo factory recovery disks) I only created one user, which has Admin rights. I don't believe I'm using the actual built-in Admin account, and I'm logging in as 'James'.

UAC is off, so it kind of sounds like the first case you mentioned in a previous post. Admin user with UAC off.
My System SpecsSystem Spec
11 Apr 2013   #23
UsernameIssues

W7 Pro SP1 64bit
 
 

When you right click on the cmd prompt shortcut, do you get a popup that has User Account Control in the title?

Try to register ole32 per post 21.
My System SpecsSystem Spec
.

11 Apr 2013   #24
jamesaru

Windows 7 Pro 64-bit
 
 

Quote   Quote: Originally Posted by Kaktussoft View Post
regsvr32 ole32.dll
regsvr32 /s ole32.dll
pause


Both commands work in elevated command prompt?
Both command work in bat file (run it elevated)?
Both of those run fine from a cmd window or a batch file (elevated and also when I don't "run as admin"). I also receive a dll registration successful message, which is something I never receive when I manually register the program dll.
My System SpecsSystem Spec
11 Apr 2013   #25
jamesaru

Windows 7 Pro 64-bit
 
 

Quote   Quote: Originally Posted by UsernameIssues View Post
When you right click on the cmd prompt shortcut, do you get a popup that has User Account Control in the title?

Try to register ole32 per post 21.
No, I don't see UAC in the right click menu, is that what you mean?


Attached Images
Can't run regsvr32 from .bat file, but can run from CMD-menu.png 
My System SpecsSystem Spec
11 Apr 2013   #26
Kaktussoft

Microsoft Community Contributor Award Recipient

Microsoft Windows 7 Home Premium 64-bits 7601 Multiprocessor Free Service Pack 1
 
 

Quote   Quote: Originally Posted by jamesaru View Post
Quote   Quote: Originally Posted by Kaktussoft View Post
regsvr32 ole32.dll
regsvr32 /s ole32.dll
pause


Both commands work in elevated command prompt?
Both command work in bat file (run it elevated)?
Both of those run fine from a cmd window or a batch file (elevated and also when I don't "run as admin"). I also receive a dll registration successful message, which is something I never receive when I manually register the program dll.
You get the successfull message only if you DON'T use /s as far as I know !!

regsvr32 command should run elevated otherwise it doesn't work. It has to set thing in HKLM or HKCR registry keys. It modifies part of registry normally unwriteable (but readable by all users).
My System SpecsSystem Spec
11 Apr 2013   #27
Kaktussoft

Microsoft Community Contributor Award Recipient

Microsoft Windows 7 Home Premium 64-bits 7601 Multiprocessor Free Service Pack 1
 
 

regsvr32 ole32.dll (unelevated) gives this popup.
regsvr32 /s ole32.dll (unelevated) gives no popup at all. It looks successfull.... but it isn't!

You have to do it with elevated privileges!! And remove the /s for troubleshooting


Attached Images
Can't run regsvr32 from .bat file, but can run from CMD-naamloos.png 
My System SpecsSystem Spec
11 Apr 2013   #28
UsernameIssues

W7 Pro SP1 64bit
 
 

Quote   Quote: Originally Posted by jamesaru View Post
Quote   Quote: Originally Posted by UsernameIssues View Post
When you right click on the cmd prompt shortcut, do you get a popup that has User Account Control in the title?

Try to register ole32 per post 21.
No, I don't see UAC in the right click menu, is that what you mean?
Yes, that is what I mean. Then it appears that you have UAC turned off.

I'll leave you to work with Kaktussoft while I lurk.
My System SpecsSystem Spec
11 Apr 2013   #29
UsernameIssues

W7 Pro SP1 64bit
 
 

Quote   Quote: Originally Posted by Kaktussoft View Post
regsvr32 ole32.dll (unelevated) gives this popup.
regsvr32 /s ole32.dll (unelevated) gives no popup at all. It looks successfull.... but it isn't!

You have to do it with elevated privileges!! And remove the /s for troubleshooting
Isn't every cmd prompt window "elevated" when UAC is off in an admin account?

I do not think that it is possible for the OP to open an unelevated cmd prompt window.

If I'm wrong - let me know. If I'm right, then it matters how you interpret the results the OP sees.
My System SpecsSystem Spec
11 Apr 2013   #30
jamesaru

Windows 7 Pro 64-bit
 
 

Yeah, I think everything is elevated. When I open a cmd prompt it always says "Administrator". Thanks for all of your assistance in trying to troubleshoot this. As a workaround I'm going to try to install the necessary software in a VM and see if I have any luck. A couple of my colleagues have been able to install without issue so it seems specific to my machine.
My System SpecsSystem Spec
Reply

 Can't run regsvr32 from .bat file, but can run from CMD




Thread Tools Search this Thread
Search this Thread:

Advanced Search




Similar help and support threads
Thread Forum
regsvr32 error
I am trying to register bthserv.dll in my registry as the bluetooth support service is missing from my services.msc; Dont ask how that happened! when running the command regsvr32 bthserv.dll im getting the error message; "the module bthserv.dll was loaded but the entry-point dllregisterserver...
BSOD Help and Support
Regsvr32 Error - PLEASE HELP
Hi All, I keep getting this error message every time I log on to my laptop. It's windows 7 64 bit. "The Module "C:\ProgramData\xklyoryq.dat" failed to load. Make sure the binary is stored at the specified path or debug it to check for problems with the binary or dependent .DLL files" ...
General Discussion
RegSvr32 Issue
The module was loaded but its entry for dll register server was not found. I suspect due to the file was downloaded from unreliable source. So what i do is try to compare from other file system that already installed in the same directory but different folder. And here's the result...
General Discussion
Regsvr32 Problems
Hi, Im running windows 7 ultimate x64 and trying to register a dll file using regsvr32, but everytime i try to in command prompt i get this error. I also tried: Running CMD as admin. Putting the dll file in the directory with the programme im trying to run. i also tried to put the dll both in...
General Discussion
regsvr32 keeps running (dialog boxes missing)
Hello World, I have a programm that is copying a file (and its needed .dll files) to a selected folder. After the copy process the .dll files need to be registered with regsvr32. This is also part of the programm. On WIN XP there have been shown a dialog box that the regstration have been...
General Discussion
Regsvr32 cannot find which program Files
I am having an import wizard problem in MS Access 2007. In trying to fix the problem, I am trying to register dao60.dll ans msado15.dll. Unfortunately, it doesn't recognize Program Files (x86) and the .dlls are not in Program Files. Any suggestions?
General Discussion


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 01:00.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App