Re: Как открыть папку так чтобы появилось окно с
От: akasoft Россия  
Дата: 22.09.03 19:17
Оценка:
Здравствуйте, Wizard_Ex, Вы писали:

W_E>Как открыть папку так чтобы появилось виндовое окно и в нем уже выделен нужный файл файл


Возможно, это поможет. Статья из МСДН.

SHOpenFolderAndSelectItems Function

--------------------------------------------------------------------------------

Opens a Microsoft® Windows® Explorer window with specified items in a particular folder selected.

Syntax

HRESULT SHOpenFolderAndSelectItems( LPCITEMIDLIST pidlFolder,
UINT cidl,
LPCITEMIDLIST *apidl,
DWORD dwFlags
);
Parameters

pidlFolder
[in] Pointer to a fully qualified pointer to an item identifier list (PIDL) that specifies the folder.
cidl
[in] Count of items in the selection array, apidl. If cidl is zero, then pidlFolder must point to a fully specified ITEMIDLIST describing a single item to select. This function opens the parent folder and selects that item.
apidl
[in] Pointer to an array of PIDL structures, each of which is an item to select in the target folder referenced by pidlFolder.
dwFlags
[in] Optional flags. In the current implementation, this parameter is ignored.
Return Value

Returns S_OK if successful, or an error value otherwise.

Remarks

CoInitialize or CoInitializeEx must be called before using SHOpenFolderAndSelectItems. Not doing so causes SHOpenFolderAndSelectItems to fail.

Function Information

Minimum DLL Version shell32.dll version 6.0 or later
Custom Implementation No
Header shlobj.h
Import library shell32.lib
Minimum operating systems Windows XP

... << RSDN@Home 1.1 beta 2 >>
 
Подождите ...
Wait...
Пока на собственное сообщение не было ответов, его можно удалить.