when you run it "through visual studio" it is launching the exe in the folder it outputs it in, which is not the same folder as your config.lua and that is the only reason it didn't find it, if you wish to debug with visual studio, just open visual studio, and then drop the exe you want to run...