String.Format を使用して次の文字列を作成しようとしています
2MSFX.exe "C:\Users\Avidan\Documents\Visual Studio 2010\Projects\DefferedRenderer\DummyGame\DummyGameContent\Shaders\Clear.fx" "C:\Users\Avidan\Documents\Visual Studio 2010\Projects\DefferedRenderer\DummyGame \DummyGameContent\Shaders\Clear.mxfb"
だから私は String.Format を使用しようとしていますが、何らかの理由で頭を悩ませることができません:|
コードは次のとおりです (最後の 2 つのパラメーターは String.Empty です)。
String outputFile = Path.Combine(destDir, Path.ChangeExtension(Path.GetFileName(fxFile), "mgxf"));
String command = String.Format("\"{0}\" \"{1}\" \"{2}\" \"{3}\"", Path.GetFullPath(fxFile), Path.GetFullPath(outputFile), DX11Support, DebugSupport);
var proc = new Process
{
StartInfo = new ProcessStartInfo
{
FileName = MGFXApp,
Arguments = command,
UseShellExecute = false,
RedirectStandardOutput = true,
CreateNoWindow = true
}
};
しかし、それは私に \"C:\Users\Avidan\Documents\Visual Studio 2010\Projects\DefferedRenderer\DummyGame\DummyGameContent\Shaders\ClearGBuffer.fx\" \"C:\Users\Avidan\Documents\Visual Studio を与えているようです2010\Projects\DefferedRenderer\DummyGame\DummyGameContent\Shaders\MGFX\ClearGBuffer.mgxf\" \"\" \"\"
逐語的な文字列を使用すると、必要な文字列を作成することができません。
何か案は?ありがとう。