Why don't Visual Basic programs run on all Windows computers?

My pretty little program only runs on two out of four computers. The others display this ugly error message:

Run time error '339" Component 'COMDLG32.OCX ' or one of it's dependencies not correctly registered: a file is missing or invalid.

There is no HINT of how to fix this problem anywhere. I've searched the Visual Studio help, these forums and the Microsoft site.

Do VB programmers just live with this problem or is there a solution



Answer this question

Why don't Visual Basic programs run on all Windows computers?

  • NicMilne

    There is similar problem that I faced. You can open your code in notepad and check the various components its referring to. Check them in Windows\System32 folder. If the file is not present then register them using regsvr32 <filename>. It should work fine. Other way can be creating installer / finding dependencies of the application using Visual Studio Tools.
  • ManServ

    Thanks Tarun.

    I used Visual Studio to make an installation package and will distribute it's zip file.

    It's not as simple as distritributing an exe, but gets the job done.

    Much obliged.


  • rahulMCA

    Did you ever get an answer to this. I just brought a new computer that runs VISTA for my wife. All of my utility programs (compiled in VB6) that use the common dialogue get this error. Run-time error '339': 'COMDLG32.OCX' or one of its dependencies not correctly registered: a file is missing or invalid.



  • Why don't Visual Basic programs run on all Windows computers?