VS2017 project does not show window when run from IDE Topic is solved

Do you have a typical platform dependent issue you're battling with ? Ask it here. Make sure you mention your platform, compiler, and wxWidgets version.
Post Reply
almonj
Earned a small fee
Earned a small fee
Posts: 16
Joined: Fri Dec 09, 2016 5:41 pm

VS2017 project does not show window when run from IDE

Post by almonj »

I have a wxWidgets project that when I run it in the VS2017 IDE everything builds and compiles but output box shows nothing when run and no window pops up. Strangely If I go to the exe folder and run it by clicking the exe everything works properly.. I have no idea why it this is happening since there are no error messages. Anyone know why this might be happening?

Output:

1>------ Rebuild All started: Project: wxgltest_vs, Configuration: Release Win32 ------
1>GL_set.cc
1>..\GL_set.cc(62): warning C4305: 'argument': truncation from 'double' to 'GLclampf'
1>Init.cc
1>M_canvas.cc
1>M_frame.cc
1>objLoader.cc
1>Generating code
1>All 906 functions were compiled because no usable IPDB/IOBJ from previous compilation was found.
1>Finished generating code
1>wxgltest_vs.vcxproj -> C:\d\wx_VISUAL_STUDIO_TESTING\wxgltest_vs\Release\wxgltest_vs.exe
1>Done building project "wxgltest_vs.vcxproj".
========== Rebuild All: 1 succeeded, 0 failed, 0 skipped ==========


here is a screenshot of the display:
Image
User avatar
doublemax
Moderator
Moderator
Posts: 19114
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: VS2017 project does not show window when run from IDE

Post by doublemax »

Is there any condition inside your program that could cause this? E.g. you're trying to load an external file and if it's not there, you just exit?
Use the source, Luke!
almonj
Earned a small fee
Earned a small fee
Posts: 16
Joined: Fri Dec 09, 2016 5:41 pm

Re: VS2017 project does not show window when run from IDE

Post by almonj »

doublemax wrote:Is there any condition inside your program that could cause this? E.g. you're trying to load an external file and if it's not there, you just exit?
It could happen if it did not find the wavefront obj file, or the shader files, but those are included in the project. Don't know why it would fail within the IDE but work if I clicked the output EXE though..
User avatar
doublemax
Moderator
Moderator
Posts: 19114
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: VS2017 project does not show window when run from IDE

Post by doublemax »

I asked because the working directory is different in both cases. If you're using relative paths to load these files, it's possible they are not found. Display a message box if a file is not found, then you see what's going on.
Use the source, Luke!
ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 7458
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: VS2017 project does not show window when run from IDE

Post by ONEEYEMAN »

Hi,
In addition to doublemax' reply, check that you do have a Manifest.

Thank you.
almonj
Earned a small fee
Earned a small fee
Posts: 16
Joined: Fri Dec 09, 2016 5:41 pm

Re: VS2017 project does not show window when run from IDE

Post by almonj »

ONEEYEMAN wrote:Hi,
In addition to doublemax' reply, check that you do have a Manifest.

Thank you.

I'm not familiar with that. Where would the manifest file be generated?
almonj
Earned a small fee
Earned a small fee
Posts: 16
Joined: Fri Dec 09, 2016 5:41 pm

Re: VS2017 project does not show window when run from IDE

Post by almonj »

doublemax wrote:I asked because the working directory is different in both cases. If you're using relative paths to load these files, it's possible they are not found. Display a message box if a file is not found, then you see what's going on.
You were right. Apparently the working directory is the place where the vcxproj file is, I put the shaders and model object in there at it worked. Thanks.
Post Reply