views:

123

answers:

1

I have created a COM component for my work. I have registered the component also.

On my system I have two VM workstations. In my first workstation it works fine. In my second workstation it displays an error box containing the message this program needs a rumtime and closes an unusual way please contact applications administrator. I thought that this was because of not registering the dll in the second worksation then I registered and it works fine.

When i tried to test the same in win2k8 machine even though I register the COM component successfully it shows the above said erroe window??

Can anyone help me understand this?

Thanks in advance...

+3  A: 

My guess is that your exe needs some other dll, which is available on one system but not on the other. On the system you get the error, use Process Monitor to watch your exe run until the error appears. If any dll is not available to you exe, you should see it there. Another tool you can use is Dependency Walker, which can point linked dlls that are not available even without running the exe.

If a dll is indeed missing, the common reasons are not installing the VC redistributables package, and SysWOW64-System32 mixups on 64 bit systems.

eran
w2k8 is 64 bit machine and the one which i have created exe is winn2k3 32 bit machine.....is it reson for that Debug error???
Cute
It might be. For 64 bit executables, the system directory is System32. For 32 bit executables, the system directory is SysWOW64. System32 is not in the search path (%PATH%) for 32 bit executables, and vise versa. This means that if other required dlls are in the wrong system directory, they will not be available. This could be easily discovered using filemon or dependency walker.
eran
s/FileMon/Process Monitor/
Richard