Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Help
»
General
»
Simple code only works when not launched by VS10
Print
Pages: [
1
]
Author
Topic: Simple code only works when not launched by VS10 (Read 1630 times)
0 Members and 1 Guest are viewing this topic.
SaturnElena
Newbie
Posts: 3
Simple code only works when not launched by VS10
«
on:
January 16, 2012, 01:42:56 am »
so I made a simple show pic code and after you click its loads a diff img
the code is pretty much copy pasted from a tutorial
but when I run it from VS10 it just shows a black window
and when ran from a win explorer it works no problem
what could cause this? :s
thank you :lol:
Logged
Tex Killer
Full Member
Posts: 242
Simple code only works when not launched by VS10
«
Reply #1 on:
January 16, 2012, 03:13:27 am »
When you run it from the VS, the current path is probably set to the project directory, but when you run it alone, the current path is the folder with the .exe file.
If you want to run it from VS, put the resources relative to that folder.
Logged
SaturnElena
Newbie
Posts: 3
Simple code only works when not launched by VS10
«
Reply #2 on:
January 16, 2012, 08:49:05 am »
Thank you kindly
this solved my problem.
Logged
Print
Pages: [
1
]
SFML community forums
»
Help
»
General
»
Simple code only works when not launched by VS10