Главная страница
    Top.Mail.Ru    Яндекс.Метрика
Форум: "Основная";
Текущий архив: 2004.09.12;
Скачать: [xml.tar.bz2];

Вниз

Как можно скопировать папку с подпапками?   Найти похожие ветки 

 
Ёмое   (2004-08-29 11:11) [0]

Как можно скопировать папку с подпапками?
Папка в ней подпапка с файлами.


 
DiamondShark ©   (2004-08-29 11:29) [1]

SHFileOperation


 
Ёмое   (2004-08-29 12:00) [2]

что это такое?


 
DiamondShark ©   (2004-08-29 12:06) [3]

Функция.


 
Ёмое   (2004-08-29 12:11) [4]

я понял что она из Api может черкнешь пример ее использования а то в help е что то ничего нет...


 
GuAV ©   (2004-08-29 12:24) [5]


> а то в help е что то ничего нет...

Да ну?
Если F1 не работает попробуй Help->Windows SDK
а лучше MSDN.


 
Ёмое   (2004-08-29 12:34) [6]

а просто написать ....?


 
GuAV ©   (2004-08-29 12:41) [7]


> а просто написать ....?


:) просто только скопировать :)

Performs a copy, move, rename, or delete operation on a file system object.

WINSHELLAPI int WINAPI SHFileOperation(

   LPSHFILEOPSTRUCT lpFileOp
  );


Parameters

lpFileOp

Pointer to an SHFILEOPSTRUCT structure that contains information the function needs to carry out the operation.



Return Values

Returns zero if successful or nonzero if an error occurs.

See Also

SHFILEOPSTRUCT

ontains information that the SHFileOperation function uses to perform file operations.

typedef struct _SHFILEOPSTRUCT { // shfos  
   HWND         hwnd;
   UINT         wFunc;
   LPCSTR       pFrom;
   LPCSTR       pTo;
   FILEOP_FLAGS fFlags;
   BOOL         fAnyOperationsAborted;
   LPVOID       hNameMappings;
   LPCSTR       lpszProgressTitle;
} SHFILEOPSTRUCT, FAR *LPSHFILEOPSTRUCT;


Members

hwnd

Handle of the dialog box to use to display information about the status of the operation.

wFunc

Operation to perform. This member can be one of the following values:

FO_COPY Copies the files specified by pFrom to the location specified by pTo.
FO_DELETE Deletes the files specified by pFrom (pTo is ignored).
FO_MOVE Moves the files specified by pFrom to the location specified by pTo.
FO_RENAME Renames the files specified by pFrom.


pFrom

Pointer to a buffer that specifies one or more source file names. Multiple names must be null-separated. The list of names must be double null-terminated.

pTo

Pointer to a buffer that contains the name of the destination file or directory. The buffer can contain mutiple destination file names if the fFlags member specifies FOF_MULTIDESTFILES. Multiple names must be null-separated. The list of names must be double null-terminated.

fFlags

Flags that control the file operation. This member can be a combination of the following values:

FOF_ALLOWUNDO Preserves undo information, if possible.
FOF_CONFIRMMOUSE Not implemented.
FOF_FILESONLY Performs the operation only on files if a wildcard filename (*.*) is specified.
FOF_MULTIDESTFILES Indicates that the pTo member specifies multiple destination files (one for each source file) rather than one directory where all source files are to be deposited.
FOF_NOCONFIRMATION Responds with "yes to all" for any dialog box that is displayed.
FOF_NOCONFIRMMKDIR Does not confirm the creation of a new directory if the operation requires one to be created.
FOF_RENAMEONCOLLISION Gives the file being operated on a new name (such as "Copy #1 of...") in a move, copy, or rename operation if a file of the target name already exists.
FOF_SILENT Does not display a progress dialog box.
FOF_SIMPLEPROGRESS Displays a progress dialog box, but does not show the filenames.
FOF_WANTMAPPINGHANDLE Fills in the hNameMappings member. The handle must be freed by using the SHFreeNameMappings function.


fAnyOperationsAborted

Value that receives TRUE if the user aborted any file operations before they were completed or FALSE otherwise.

hNameMappings

Handle of a filename mapping object that contains an array of SHNAMEMAPPING structures. Each structure contains the old and new path names for each file that was moved, copied, or renamed. This member is used only if fFlags includes FOF_WANTMAPPINGHANDLE.

lpszProgressTitle

Pointer to a string to use as the title for a progress dialog box. This member is used only if fFlags includes FOF_SIMPLEPROGRESS.



Remarks

If pFrom or pTo are unqualified names, the current directories are taken from the global current drive and directory settings as managed by the GetCurrentDirectory and SetCurrentDirectory functions.

See Also

GetCurrentDirectory, SetCurrentDirectory, SHFileOperation, SHFreeNameMappings, SHNAMEMAPPING


 
KSergey ©   (2004-08-29 12:47) [8]

> [4] Ёмое   (29.08.04 12:11)
> я понял что она из Api может черкнешь пример ее использования
> а то в help е что то ничего нет...

А еще есть яндекс...


 
Ёмое   (2004-08-29 19:02) [9]

Всем спасибо большое.



Страницы: 1 вся ветка

Форум: "Основная";
Текущий архив: 2004.09.12;
Скачать: [xml.tar.bz2];

Наверх




Память: 0.47 MB
Время: 0.036 c
1-1093509975
serg128
2004-08-26 12:46
2004.09.12
Вопрос по свойству WindowMenu


3-1092496684
miwa
2004-08-14 19:18
2004.09.12
Как правильно сохранить объекты в базе?


3-1092654497
yaric
2004-08-16 15:08
2004.09.12
Программная деактивация тригерра


14-1093032386
Knight
2004-08-21 00:06
2004.09.12
Вопрос к знатокам третьей кваки - арена...


14-1093256734
Slider007
2004-08-23 14:25
2004.09.12
Shift+Insert





Afrikaans Albanian Arabic Armenian Azerbaijani Basque Belarusian Bulgarian Catalan Chinese (Simplified) Chinese (Traditional) Croatian Czech Danish Dutch English Estonian Filipino Finnish French
Galician Georgian German Greek Haitian Creole Hebrew Hindi Hungarian Icelandic Indonesian Irish Italian Japanese Korean Latvian Lithuanian Macedonian Malay Maltese Norwegian
Persian Polish Portuguese Romanian Russian Serbian Slovak Slovenian Spanish Swahili Swedish Thai Turkish Ukrainian Urdu Vietnamese Welsh Yiddish Bengali Bosnian
Cebuano Esperanto Gujarati Hausa Hmong Igbo Javanese Kannada Khmer Lao Latin Maori Marathi Mongolian Nepali Punjabi Somali Tamil Telugu Yoruba
Zulu
Английский Французский Немецкий Итальянский Португальский Русский Испанский