[RESOLVED] VB6 IDE vs EXE errors
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: [RESOLVED] VB6 IDE vs EXE errors

Hybrid View

  1. #1
    Join Date
    May 2011
    Posts
    6

    [RESOLVED] VB6 IDE vs EXE errors

    I have a legacy VB6 program that I am updating to Win7. This is a machine vision app, with a new DLL from a camera vendor.

    I have a very simple VB6 test program that works great with the new DLL - both in the IDE, and as a compiled EXE.

    When I add the updated code to my main project, the program works flawlessly when run from the IDE, but fails simple calls when compiled as an EXE.

    i.e. - there is a simple function call to identify any camera devices connected to the computer. If I add a call to this function as the first line of code in the opening form, it works through the IDE, but returns an empty string when run as an EXE. Again, this works fine, with a much simpler project.

    Somehow, adding additional forms, modules, and/or project components or references, breaks the EXE.

    I have tried Win7 options of 'XP compatibility mode' and 'run as admin' - but nothing seems to help.

    What's different between the IDE and the compiled EXE environments?

    Additional possible clue: 'sometimes' when run from the IDE, I get the following error message:

    "Can't create window of class wxWindowClassNR (error 0: the operation completed successfully.)"

    This in itself boggles my mind: an error message, followed by a statement that the err number is 0, and no error????

    Any clues to any of the above would be appreciated...

  2. #2
    Join Date
    May 2011
    Posts
    6

    Re: [RESOLVED] VB6 IDE vs EXE errors

    Problems solved! There was basically nothing wrong with my code. The main project contains 51 files (forms and modules). For historical (and hysterical?) purposes, I 'conveniently' archived all dependent DLL's in this same project folder during development days in Windows XP - and then forgot about them.

    When the updated project was executed from the IDE, the correct Windows7 DLL files were used. When the EXE file was run from folder, the old WinXP DLL's in the same folder were used!

    Doh!!! What a way to waste an entire weekend!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center