How to get a string with the solution directory in the code?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • DonMatteo
    New Member
    • Mar 2008
    • 5

    #1

    How to get a string with the solution directory in the code?

    Hi there,

    Is there anyway to get a string equivalent to the $(SolutionDir) defined in the C++ properties. I heard about the macro __FILE__. Is there anything equivalent for the solution directory? If not, how can I get in from the code?

    I need it to print some results in a txt file in the solution directory. Is that possible?

    Many thanks,

    Matteo
  • Sick0Fant
    New Member
    • Feb 2008
    • 121

    #2
    Why the double post?

    Anyway, if you are programming for Windows, you have the GetModuleFileNa me API function.

    Comment

    Working...