I have a batch file two levels up.
..\..\PostBuildEventCopy.bat $(TargetDir) $(TargetName)
This batch file copies certain files to a location mentioned in the batch file. I get the below error. It seems to me that VS is not able to find the batch file.
Error: '..\..\PostBuildEventCopy.bat' is not recognized as an internal or external command, operable program or batch file.
But when I mention the full path to the batch file, post build event goes through.
Am I missing something here? Any help appreciated.
Just means that it doesn't find your
batfile. And i'm pretty sure that this is the problem! ;) - if you haven't changed your output directory from.\bin\debugor.\bin\releaseit means you have to store this file in your project directory. The two levels up gets resolved from the output directory!Also be sure to add thestartcommand before your bat-call.My postbuild event for 2 levels up looks like this:
and the
test.batis in the root of my project directory.