You don't need to use the string literal operator (@) on a variable. Remove it and see if that works. Usually you would see it's use only when you are inputting a new string that you don't want escaped e.g. string blah = @"this\string\shouldn't\be\escaped";
Failing that, what is the value of PIoutput? Certain characters are not allowed in file paths such as any of:
: ? * " < > |
Best Regards,
BioPhysEngr http://blog.biophysengr.net
--
All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.
I took the "@" out and it still did not work. My output file is defined in the text file as.... string.Format("{0}{1}Metdata_MT-{2:yyyy-MM-dd}.txt", Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), Path.DirectorySeparatorChar, DateTime.Now)
Per what you said, I am assuming this is what is causing the error. lol. But how do I set the output file to this format?
Hrm. I see nothing obviously wrong with that. What value does PIoutput have in the debugger?
Best Regards,
BioPhysEngr http://blog.biophysengr.net
--
All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.
Then use the debugger to see the value assigned to PIOutput and post it here (or examine it and figure out why it's an invalid path).
Best Regards,
BioPhysEngr http://blog.biophysengr.net
--
All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.
Bookmarks