CopyFiles using IFileOperation (C++) -


I want to copy many files using IFileOperation. The copy of a file is not a problem like this example:

My problem is that I have no way to copy many files like * .txt I use SHCreateShellItemArrayFromIDLists as this script Have tried:

  IShellItem * psiTo = NULL; HRESULT hr = SHCreateItemFromParsingName (CST arget, NULL, IID_PPV_ARGS (and psiTo)); LPCIIDIDILITIILIDPIILFIfile = ILCraftPath (CSSOSRS); UINT calculation = size (pedal); Ishel Itamayre * psiafiles = NULL; Hour = SHCreateShellItemArrayFromIDLists (counting, and pidlFiles, and psiaFiles); Hr = pfo- & gt; Copyimes (psiaFiles, psiTo); Hr = pfo- & gt; Display operation ();   

Use SHCreateShellItemArray in another way, such as:

  LPCITEMIDLIST pidlParent = ILCreateFromPath (_T ("C: \\")); LPCITEMIDLIST pidlChild = ILCreateFromPath (_T ("C: \\ Temp \\ *. Txt")); HRESULT hr = SHCreateShellItemArray (Pedalperant, Faucet, 1, & Pidil Child, and PsfaFile); Hr = pfo- & gt; Copyimes (psiaFiles, psiTo); Hr = pfo- & gt; Display operation ();   

I tried differently but almost got me E_INVALIDIDARG or ERROR_PATH_NOT_FOUND. What is wrong?

ILTR does not take wildcards because it is a single PIDLIST_ABSOLUTE returns

The easiest solution is to manually file FindFirstFile (* .txt) , call CopyItem each result Then, and then call PerformOperations Once Upon End

As always, older Windows functions are better SHFileOperation <1081> Simple and easy to boot Has: It's straight wildcaster E supports.

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -