hi

I was programming with dev c++ for a while.
I decided to move everything to visual studio for a reason.

Here is the problem I have

1. when launch the executable in visual studio - using start without debugger or with debugger - the application says it can't find QnA.xml - an XML file used in my application in the Question.cpp file.

But when I launch the executable outside the visual studio environment - (by double-clicking the executable) the executable starts up fine and finds the QnA.xml file.

Here's the code in my question.cpp file.
Code:
void initialize(bool bisOrdered)
{
    isOrdered = bisOrdered;
    TiXmlDocument doc( "QnA.xml");
    bool loadOkay = doc.LoadFile();
    bool firstQuestion = false;

    if( !loadOkay )
    { 
          MessageBox( NULL, "Can't load QnA.xml", "Error", MB_OK | MB_ICONERROR | MB_SYSTEMMODAL ) ; 

    }
    // ... etc. 
}
When I start up the application, inside visual studio I see the messagebox.
When I start up the application outside visual studio I don't see the message box it appears everything loads just fine.

These problems never existed when I was using Dev C++

Any thoughts ?


Stephen

I don't know if this is a clue but I am also posting on another problem upon shutting down in another thread.