Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. File open dialog misery

File open dialog misery

Scheduled Pinned Locked Moved C / C++ / MFC
csharphelpvisual-studioalgorithmstools
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Rick Dangerous
    wrote on last edited by
    #1

    Hi, I have created an Explorer extension to provide a custom column. This column is quite happy being turned on and off on a per folder basis in Explorer - I can tell any particular folder whether to display the column. Now, in my application, I want to do a file open dialog (CFileDialog, GetOpenFilename() etc). This is all ok and after no small effort I have managed to get this dialog to use the 'Report' view by default for the ListView control. The problem is that the dialog only shows the default columns (Name, Size, Type etc...) and pays no attention to the individual folder settings - thus my column is not displayed even if the particular folder is supposed to be showing it. I can select the column to be displayed in a folder but then if I browse to another and return the column settings have disappeared. If I tell every folder to display the column (Tools-Folder Options-View-Like Curent Folder) then the column wil be displayed in my file open dialog. However, I don't want this column to be displayed for every single folder in Explorer (I intend adding quite a few more columns which show information inappropriate to most folders). I know about the SHELLDEF_View and SysListView32 classes that implement the ListView control and can get to the interfaces below: IID_IShellFolder2 IID_IShellIcon IID_IPersistFolder3 IID_IShellIconOverlay None of these interfaces appear to have methods that allow me to manipulate the columns shown. I know I can manually add columns with ListView.InsertColumn() but then there is no way of populating the control properly (or is there?) and it seems to blow up if I try and change views. Does anyone know of a way of telling the control which columns to show, and to get it to remember which columns are to be shown. I know it can be done (Visual Studio.net has a dialog such as I need but it's quite possible that that uses it's own which just happens to be very similar to the standard dialog) but how? I really cannot believe that one of the most used dialog boxes in the known universe is such a pain in the ar** to use (well obviously I can but even so...). Do I have to implement my own IShellView + place it over the top of the standard one? This would be annoying due to having to implemnent the sorting, right click etc. Thanks for any help on this particularly matter because it's driving me up the wall : ) Rick Dangerous

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups