我用winexec执行了一个bat命令,同时通过时钟每秒检索,但如何知道bat命令文件已执行完毕呢?因为如果结束执行了,我就要停止时钟,接下去做其他的事情了呀!

解决方案 »

  1.   

    ??bat可以返回什么参数呢?还是Winexec函数的返回?如果可以,能说的具体些吗?谢谢了。
      

  2.   

    在bat结束的时候写一个文件吧,检测文件是否存在就可以了。
      

  3.   

    >>在bat结束的时候写一个文件吧,检测文件是否存在就可以了。如果这样的话,在bat开始的时候要del这个文件if exists filename then del filename
    rem other operations
    rem end of other operations
    if not exists filename then copy nul filename
      

  4.   

    不要在bat里进行文件删除,有可能会出错。在程序里删除文件,确认文件已经被删除,然后调用bat
      

  5.   

    rem other operations
    rem end of other operations
    是什么东东呀,看不懂。而且问一下,这些东东是写在bat里的吗?
      

  6.   

    [TO Manwill71(天皇地虎江山一片)]
    在bat里如何写文件呢?
      

  7.   

    在bat 里面写文件.
    dir >text.txt