C#中的处理代码 [英] Process Code in C#
问题描述
你好
希望有人可以帮助我解决我的小问题.我有一个.bat文件,该文件可以调用.exe,并且确实可以将文件转换为某些文件.
Hope some one can help me with my little problem. I have a .bat file that call an .exe and waht it does is convert the file into something.
如果单击.bat文件,该文件可以正常运行,但是当我在应用程序中调用bat文件时,则没有任何效果..请帮助.
The .bat file work ok if i click on it, but when i call the bat file in my application NOTHING works.. Please help.
有人可以帮我把它翻译成C#代码吗?
Can some one help me translate this to C# code?
我认为我正在寻找的过程是开始***某事
I think what im looking for is that process.start *** something
请帮助
rem Batch file for converting several XZY files to DXF
rem Command line parameter '-cfg': Translator requires a .def file to run.
rem Usage: [-cfg configuration_file_name] [-m mode] [-f file_filter]
rem -? Displays this help
rem -cfg Followed by a space and name of the configuration file
rem -m Followed by mode of operation. Either 'browse' , 'batch' , or 'single'.
rem -f Followed by a file filter expression if in 'browse' or 'batch' mode OR a
rem file name if in 'single' mode.
echo. -- Start XYZ to DXF conversion ---
C:\test\progs.exe -cfg C:\test\conersion.def -m batch -f *.nc
推荐答案
像这样的事情?
Something like this?
Process.Start("C:\ test \ progs.exe" , " C:\ test \ conersion.def -m批处理-f * .nc")
Process.Start("C:\test\progs.exe", "C:\test\conersion.def -m batch -f *.nc")
希望这会有所帮助.
这篇关于C#中的处理代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!