//SWF文件生成
string cmdpath = "C:\WINDOWS\system32\cmd.exe";
string swfpath = "";//Flash工具所在路径
string cmdpath = "C:\WINDOWS\system32\cmd.exe";
string swfpath = "";//Flash工具所在路径
Process p = new Process();
p.StartInfo.FileName = cmdpath;
p.StartInfo.UseShellExecute = false;
p.StartInfo.RedirectStandardInput = true;
p.StartInfo.RedirectStandardOutput = true;
p.StartInfo.RedirectStandardError = true;
p.StartInfo.CreateNoWindow = true;
p.Start();
string strOutput = null;
p.StandardInput.WriteLine(exepath + " " + sourcepath + " -o " + despath);
//p.StandardInput.WriteLine(@"c:\FlashPaper2.2\FlashPrinter.exe c:\测试文档.txt -o c:\output.swf");
p.StandardInput.WriteLine("exit");
strOutput = p.StandardOutput.ReadToEnd();
Console.WriteLine(strOutput);
p.WaitForExit();
p.Close();
//SWF打开
//SWF文件打开
<embed id=\'swf\' src=\'c:\output.swf\' quality=\'high\' width=\'1000\' height=\'600\' name=\'as-js\' align=\'middle\' allowscriptaccess=\'always\' type=\'application/x-shockwave-flash\' pluginspage=\'http://www.macromedia.com/go/getflashplayer\' />
<embed id=\'swf\' src=\'c:\output.swf\' quality=\'high\' width=\'1000\' height=\'600\' name=\'as-js\' align=\'middle\' allowscriptaccess=\'always\' type=\'application/x-shockwave-flash\' pluginspage=\'http://www.macromedia.com/go/getflashplayer\' />