1. Error running bound exe

My exe runs fine on one machine, however when I copy it to another machine and run it I get an error msg like this: Myapp.exw:1 c_proc/c_func: bad routine number (-1)

help pointing me to why it fails on one machine but not another is much appreciated.

new topic     » topic index » view message » categorize

2. Re: Error running bound exe

Most likely you are missing a DLL the code is trying to open.

new topic     » goto parent     » topic index » view message » categorize

3. Re: Error running bound exe

cp said...

My exe runs fine on one machine, however when I copy it to another machine and run it I get an error msg like this: Myapp.exw:1 c_proc/c_func: bad routine number (-1)

help pointing me to why it fails on one machine but not another is much appreciated.

We need a little more information. This error says that it couldn't load some function from a dll.

  1. Are you using any custom dlls (i.e., not provided by the operating system)? If so, are they where the exe expects them to be (probably in the same directory)?
  2. Do both machines run the same operating system? Your application could be using something introduced in a particular version of Windows, but now you're running on an earlier version.

I suspect that the answer is number 1, but most likely one of these is the issue.

Matt

new topic     » goto parent     » topic index » view message » categorize

4. Re: Error running bound exe

Yes I have include files that wrap a custom DLL but the DLL is registered and exists on both machines in the same location.

both machines are running windows XP

one thing that is strange that I thought was the cause of the issue is that one of my include files was located in the same dir as my exw source but not in my euphoria\include dir. I did the bind without error and the exe ran fine on that machine.

new topic     » goto parent     » topic index » view message » categorize

5. Re: Error running bound exe

cp said...

Yes I have include files that wrap a custom DLL but the DLL is registered and exists on both machines in the same location.

both machines are running windows XP

What about that custom DLL's dependencies? It may require another dll that exists on the one machine but which is missing on the other.

cp said...

one thing that is strange that I thought was the cause of the issue is that one of my include files was located in the same dir as my exw source but not in my euphoria\include dir. I did the bind without error and the exe ran fine on that machine.

Binding merges all the include files into the .exe, so having extra copies lying around won't affect things.

new topic     » goto parent     » topic index » view message » categorize

6. Re: Error running bound exe

cp said...

Yes I have include files that wrap a custom DLL but the DLL is registered and exists on both machines in the same location.

both machines are running windows XP

one thing that is strange that I thought was the cause of the issue is that one of my include files was located in the same dir as my exw source but not in my euphoria\include dir. I did the bind without error and the exe ran fine on that machine.

I doubt it is an include file. You say that the dll was in the same location. This may not be enough. Here is how Windows searches for dlls:

MSDN said...
  1. The directory where the executable module for the current process is located.
  2. The current directory.
  3. The Windows system directory. The GetSystemDirectory function retrieves the path of this directory.
  4. The Windows directory. The GetWindowsDirectory function retrieves the path of this directory.
  5. The directories listed in the PATH environment variable.

Does your dll fit into this on the second machine?

Matt

new topic     » goto parent     » topic index » view message » categorize

7. Re: Error running bound exe

jimcbrown said...

What about that custom DLL's dependencies? It may require another dll that exists on the one machine but which is missing on the other.

That's a good point. Dependency Walker is a great tool for debugging dependencies.

Matt

new topic     » goto parent     » topic index » view message » categorize

8. Re: Error running bound exe

jimcbrown said...
cp said...

Yes I have include files that wrap a custom DLL but the DLL is registered and exists on both machines in the same location.

both machines are running windows XP

What about that custom DLL's dependencies? It may require another dll that exists on the one machine but which is missing on the other.


Or even the same version of the dll. Different versions can have different exported names. I tend to keep everything needed for a project in the same dir.

useless

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu