解决方案 »

  1.   

    不用system,用CreateProcess。PROCESS_INFORMATION piProcInfo; 
    STARTUPINFO siStartInfo;
    BOOL bSuccess = FALSE; 

    ZeroMemory( &piProcInfo, sizeof(PROCESS_INFORMATION) );

    ZeroMemory( &siStartInfo, sizeof(STARTUPINFO) );
    siStartInfo.cb = sizeof(STARTUPINFO); 
    siStartInfo.hStdError = m_hChildStd_OUT_Wr;
    siStartInfo.hStdOutput = m_hChildStd_OUT_Wr;
    siStartInfo.hStdInput = m_hChildStd_IN_Rd;
    siStartInfo.wShowWindow = wShowWindow;
    siStartInfo.dwFlags |= STARTF_USESTDHANDLES | STARTF_USESHOWWINDOW;

    bSuccess = CreateProcess(lpApplicationName, 
    lpCommandLine, // command line 
    NULL,          // process security attributes 
    NULL,          // primary thread security attributes 
    TRUE,          // handles are inherited 
    0,             // creation flags 
    NULL,          // use parent's environment 
    NULL,          // use parent's current directory 
    &siStartInfo,  // STARTUPINFO pointer 
    &piProcInfo);  // receives PROCESS_INFORMATION 大概如上,是我摘取的一段代码,楼主可参考下。
      

  2.   

    lpCommandLine定义为什么类型,把字符串"svm-scale -r allrange test.txt >> test_ind_scaled"赋值给lpCommandLine
      

  3.   

    lpCommandLine定义为什么类型,把字符串"svm-scale -r allrange test.txt >> test_ind_scaled"赋值给lpCommandLine
    这么简单的你就可以查查MSDN或者百度了吧。
      

  4.   

    lpCommandLine定义为什么类型,把字符串"svm-scale -r allrange test.txt >> test_ind_scaled"赋值给lpCommandLine
    这么简单的你就可以查查MSDN或者百度了吧。
    有前辈在,经验胜过个人再花时间去研究,能否直接告知?
      

  5.   

    lpCommandLine定义为什么类型,把字符串"svm-scale -r allrange test.txt >> test_ind_scaled"赋值给lpCommandLine
    这么简单的你就可以查查MSDN或者百度了吧。
    有前辈在,经验胜过个人再花时间去研究,能否直接告知?
    http://baike.baidu.com/view/697167.htm?fr=aladdin
    你这种想法就不对。
      

  6.   

    WinExec("svm-scale.....",SW_HIDE);  
      

  7.   

    ShellExecute(  HWND hwnd,           //父窗口句柄 (如:NULL,Handle等)  LPCSTR lpOperation, //操作类型 (如:"open")*要加英文双引号  LPCSTR lpFile,           //要进行操作的文件或路径  LPCSTR lpParameters, //当lpOperation为“explore”时指定要传递的参数,通常设为NULL  LPCSTR lpDirectory,    //指定默认目录,通常设为NULL  INT nShowCmd          //文件打开的方式,以通常方式还是最大化或最小化显示,一般为SW_SHOWNORMAL  ) ●ShowCmd:若FileName参数是一个可执行程序,则此参数指定程序窗口的初始显示方式,否则此参数应设置为0。