在程序中用system("cmd.exe");建立新的cmd窗口写入字符串并执行。怎样实现?
system("cmd.exe /k 你的命令");写入字符串system("cmd.exe /k echo 你的字符串");
cmd /c 命令,或者cmd /k 命令。