我用SHFileOperation这个API函数对某个盘的文件进行全盘复制,复制时,我不想要出现复制的对话框,应该怎么做啊,是不是填充SHFILEOPSTRUCT结构时注意那些啊???请高人指点指点

解决方案 »

  1.   

    of couse you can use parameter "hide" to realize.
      

  2.   

    for more information please consult with MSDN
      

  3.   

    SHFILEOPSTRUCT FileOp;
    memset(&FileOp, 0, sizeof(FileOp));FileOp.fFlags=FOF_SILENT;//大概是这个//如果不是 你从低下挑着试吧。
    /*
    #define FOF_CONFIRMMOUSE           0x0002
    #define FOF_SILENT                 0x0004  // don't create progress/report
    #define FOF_RENAMEONCOLLISION      0x0008
    #define FOF_NOCONFIRMATION         0x0010  // Don't prompt the user.
    #define FOF_WANTMAPPINGHANDLE      0x0020  // Fill in SHFILEOPSTRUCT.hNameMappings
                                          // Must be freed using SHFreeNameMappings
    #define FOF_ALLOWUNDO              0x0040
    #define FOF_FILESONLY              0x0080  // on *.*, do only files
    #define FOF_SIMPLEPROGRESS         0x0100  // means don't show names of files
    #define FOF_NOCONFIRMMKDIR         0x0200  // don't confirm making any needed dirs
    #define FOF_NOERRORUI              0x0400  // don't put up error UI
    #define FOF_NOCOPYSECURITYATTRIBS  0x0800  // dont copy NT file Security Attributes
    */