You can get the text of the selected item as a list of the general dialog. But you can’t get its PIDL, and if the user decided to hide the known extensions (by default), then you can’t say which file was selected without its extension or its PIDL.
The following solutions to this problem are possible:
- Get IShellView from the standard file open dialog. the underlying IShellView can say the PIDL for the current selection. So if I could just get ahold of IShellView, I would be golden. Unfortunately, I do not see CDM_xxx that will do this. And I can’t think of a head no matter what happens !!! :(
- Some other ideas ?!
We are used to relying on the fact that the version of Windows 9x, 2000 and XP in the general file dialog box stored each PIDL element in the LVITEM data (original Paul DiLascia loan):
LPCITEMIDLIST pidlItem = (LPCITEMIDLIST) pListCtrl-> GetItemData (nItem);
However, starting with general Vista controls and above, this method fails: (
Any thoughts?
EDIT: I need to get this information not only for the currently selected item in the list view, but for all elements in the list view.
EDIT2: The reason I need to dig so deep:
: (1) " ", , , , , . - 3 , "J1329192" ( 3 "J1329192.xyz" "J1329192.xzy" "J1329192.zyx" [ ) .
" :", , , , . , , , , , ( ).
- , , .. ( ) Vista. Vista, . , ( X?!)
, . ", , X"? - Microsoft, , . . , . , , , MS . - , , , , , , , , - , - ( ).