• Installshield 文件及文件夹操作


    http://www.yesky.com/385/153885.shtml

     其实用XCopyFile进行文件夹拷贝只需要一句话:
    nResult = XCopyFile("C:...//SrcDir//*.*","C:...//TargetDir//*.*",COMP_NORMAL);

    ///////////////////////////////////////////////////////////////////////////////
    //  EVENT:      Installed event is sent just after files for the component:
    //              PLC are transferred.
    ///////////////////////////////////////////////////////////////////////////////


    export prototype PLC_Installed();
    function PLC_Installed()
    begin  
     // 注意必须在  PLC_Installed 而不是在 PLC_Installing ,因为此时 PLC 文件夹可能还没有建立
     CreateDir (TARGETDIR^"PLC\\App_Data");
     CreateDir (TARGETDIR^"PLC\\PLC_log");
     CreateDir (TARGETDIR^"PLC\\PLC_resources");
     XCopyFile ("F:\\LEADSHOW PACKAGE SRC FILE\\plc\\App_Data\\*.*", TARGETDIR^"PLC\\App_Data", INCLUDE_SUBDIR);
     //XCopyFile ("F:\\LEADSHOW PACKAGE SRC FILE\\plc\\App_Data\\*.*", TARGETDIR^"PLC\\App_Data\\", INCLUDE_SUBDIR);
     //XCopyFile (TARGETDIR^"PLC\\App_Data", "F:\\LEADSHOW PACKAGE SRC FILE\\plc\\App_Data\\*.*", INCLUDE_SUBDIR);

     XCopyFile ("F:\\LEADSHOW PACKAGE SRC FILE\\plc\\PLC_resources\\*.*", TARGETDIR^"PLC\\PLC_resources", INCLUDE_SUBDIR);
    end;


    ///////////////////////////////////////////////////////////////////////////////
    //  EVENT:      Uninstalled event is sent just after files for the component:
    //              PLC are removed during uninstallation.
    ///////////////////////////////////////////////////////////////////////////////
     
    export prototype PLC_UnInstalled();
    function PLC_UnInstalled()     
    begin
     DeleteDir(TARGETDIR^"PLC", ALLCONTENTS);
    end;


    本文来自CSDN博客,转载请标明出处:http://blog.csdn.net/carl2380/archive/2010/08/20/5826114.aspx

  • 相关阅读:
    [APIO2014]序列分割
    [HNOI2008]玩具装箱TOY
    [ZJOI2007]时态同步
    [FJOI2014]最短路径树问题
    [IOI2011]Race
    [国家集训队]聪聪可可
    矩阵加速递推
    Codeforces Round #669 题意及思路
    Codeforces Round #670 题意及思路
    Codeforces Round #671 题意及思路
  • 原文地址:https://www.cnblogs.com/carl2380/p/2093408.html
Copyright © 2020-2023  润新知