954,499 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Cannot open program

Hi guys , after finishing my text based game , when i send the executable file to my friend he cannot open it .. he get an error that smth is wrong in configs file .. he also has framework installed

xVent
Junior Poster in Training
54 posts since Dec 2008
Reputation Points: 10
Solved Threads: 0
 

Actually this is not very C++ related I think, but OK, can you tell me what error he's having and can you provide me a link to or attach the source of your game to this thread ?

tux4life
Nearly a Posting Maven
2,350 posts since Feb 2009
Reputation Points: 2,134
Solved Threads: 243
 

The problem is most likely DLLs. I have seen similar error on Vista. Make sure you compile the program for Release mode, not Debug mode. How to do that will depend on the compiler you are using.

Ancient Dragon
Retired & Loving It
Team Colleague
30,049 posts since Aug 2005
Reputation Points: 5,662
Solved Threads: 2,343
 

So you're saying that if you take the exact same exe and config file that works on your machine and transfer it to your friend's machine, it doesn't work?

Does he have the exact same OS as you? Has he installed your program in the same way as you have?

nucleon
Posting Pro in Training
478 posts since Oct 2008
Reputation Points: 163
Solved Threads: 91
 
The problem is most likely DLLs. I have seen similar error on Vista. Make sure you compile the program for Release mode, not Debug mode. How to do that will depend on the compiler you are using.

well i gave him the executable file from debug folder .. how can i do what with release ?So you're saying that if you take the exact same exe and config file that works on your machine and transfer it to your friend's machine, it doesn't work?

Does he have the exact same OS as you? Has he installed your program in the same way as you have?
i gave him just the executable file .. tried with all debug folder ..

@The error says that there is a problem with projects configs ... i dont have any weird thing ... just texts , ifs and whiles ..

xVent
Junior Poster in Training
54 posts since Dec 2008
Reputation Points: 10
Solved Threads: 0
 

> What IDE are you using, Code::Blocks ?
> In Code::Blocks it's easy: Somewhere on the toolbar there's a listbox called Build Target , here you can specify your build configuration :) ...

tux4life
Nearly a Posting Maven
2,350 posts since Feb 2009
Reputation Points: 2,134
Solved Threads: 243
 
well i gave him the executable file from debug folder .. how can i do what with release ? .

Yes, that is most likely the problem because the other computer doesn't have the compiler's debug dlls installed. How to get release mode depends on the compiler you used, which you failed to mention.

Ancient Dragon
Retired & Loving It
Team Colleague
30,049 posts since Aug 2005
Reputation Points: 5,662
Solved Threads: 2,343
 

i use Visual Studio C++ 2008 , on Build Menu , it says Batch Build .. , i clicked Release and it compiled some stuff into release folder , but i dont see any exe in the folder .. what should i give him?

xVent
Junior Poster in Training
54 posts since Dec 2008
Reputation Points: 10
Solved Threads: 0
 
i use Visual Studio C++ 2008 , on Build Menu , it says Batch Build .. , i clicked Release and it compiled some stuff into release folder , but i dont see any exe in the folder .. what should i give him?


> Check out this page :) ...

tux4life
Nearly a Posting Maven
2,350 posts since Feb 2009
Reputation Points: 2,134
Solved Threads: 243
 

1k thanks to all , its working

xVent
Junior Poster in Training
54 posts since Dec 2008
Reputation Points: 10
Solved Threads: 0
 

When you use Windows Explorer to navigate to the release folder it will look something like the attached. If there is no *.exe file then your compiler failed to build the program. Make sure there were no compile errors.

Attachments Untitled.jpg 35.08KB
Ancient Dragon
Retired & Loving It
Team Colleague
30,049 posts since Aug 2005
Reputation Points: 5,662
Solved Threads: 2,343
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You