I've been trying to use a redirected text file as input for debugging my project. However I cannot get Visual Studio to actually execute any of the commands I have in the text file.
I've attempted to read up on a few other Stack Overflow questions but cannot figure out how to actually get the commands to execute.
And of course I attempted to read the MSDN documentation, however the closest I could get to was this:
Image
The following is also a sample of my command inputs:
add Gregory Whitfield,U-61306479,[email protected],4,3,5
add Brandon Hoffman,U-48162864,[email protected],1,0,5
add Gabriel Horne,U-49358227,[email protected],3,2,0
add Emmanuel Wilson,U-25720188,[email protected],6,1,0
add Wing Paul,U-05895915,[email protected],4,3,2
add Dustin Nielsen,U-77163005,[email protected],2,2,2
add Timon Hooper,U-23370163,[email protected],6,2,3
add Uriah Silva,U-31580761,[email protected],1,2,5
add Abbot Austin,U-87255621,[email protected],4,0,0
add Sylvester George,U-57782586,[email protected],-1,0,1
add being a command of the program I want to test.
And finally, the debugging properties I currently have (however I've tried a lot of different command arguments):
Command Arguments here
Could someone tell me what I need to input for the command arguments to actually get this to work?
1 Answer 1
You're using a relative file name. If you look at a trace of Process Monitor (SysInternals) with a filter like
Path contains TestData.txt then Include
you'll see that Visual Studio tries to load the file from the project directory.
Possible solutions:
- move
TestData.txtto the root of the project - specify a full path (maybe using variables)
- specify a relative path like
Debug\TestData.txt
Comments
Explore related questions
See similar questions with these tags.