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
  1. Home
  2. General Programming
  3. C#
  4. Open File Dialog Box

Open File Dialog Box

Scheduled Pinned Locked Moved C#
jsonquestion
2 Posts 2 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.
  • S Offline
    S Offline
    Satish Pai
    wrote on last edited by
    #1

    Hi Experts, I want to add shortcut in places bar in Open File Dialog Box.I know we can archive it using Regedit,But like to know how can i do it using Windows API (Hooking). Urgently.....

    OriginalGriffO 1 Reply Last reply
    0
    • S Satish Pai

      Hi Experts, I want to add shortcut in places bar in Open File Dialog Box.I know we can archive it using Regedit,But like to know how can i do it using Windows API (Hooking). Urgently.....

      OriginalGriffO Offline
      OriginalGriffO Offline
      OriginalGriff
      wrote on last edited by
      #2

      If I read you correctly, what you want to do is modify the "Places" pane of the standard windows "Open" and "Save" dialogs, to include custom locations rather than just the standard "My Documents" and "My Computer" etc. You can do this in two ways, but they both mean editing the registry, either by hand or by software. This works in XP, don't know about Vista X| Note that Office has its own set of "Places" pane settings, which varies depending on which version you are using (Thanks, Microsoft! Standards! Lovely!). The key you are interested in is:

      HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\ComDlg32\PlacesBar

      If it does not exist, create it. WARNING: the existance of this key overrides standard Windows behaviour and removes all items from the "Places" pane - you can delete this key to restore them. You now need to create up to five values, named "Place0" to "Place4" inclusive, and items will be displayed in this order, with Place0 at the top of the pane. The values can be string as in "E:\Correspondance", or DWORD as in the following table. The DWORD values give you access to the standard items that existed before you started changing the registry - for example, if you set "Place0" to DWORD 5, the top item, in the pane will be "My Documents" This list is (probably) not exhaustive, but if you find others that are useful, let me know. The list is (obviously) in Hex:

      0 Desktop
      1 Internet Explorer
      2 Start Menu\Programs
      3 My Computer\Control Panel
      4 My Computer\Printers
      5 My Documents
      6 \Favorites
      7 Start Menu\Programs\Startup
      8 \Recent
      9 \SendTo
      a \Recycle Bin
      b \Start Menu
      c logical "My Documents" desktop icon
      d "My Music" folder
      e "My Videos" folder
      10 \Desktop
      11 My Computer
      12 Network Neighborhood (My Network Places)
      13 \nethood
      14 Windows\Fonts
      16 All Users\Start Menu
      17 All Users\Start Menu\Programs
      18 All Users\Startup
      19 All Users\Desktop
      1a \Application Data
      1b \PrintHood
      1c \Local Settings\Applicaiton Data (nonroaming)0x001d // nonlocalized startup
      1e Nonlocalized common startup
      1f Common favorites
      20 Internet Cache
      21 Cookies
      22 History
      23 All Users\Application Data
      24 GetWindowsDirectory()
      25 GetSystemDirectory()
      26 C:\Program Files
      27 C:\Program Files\My Pictures
      28 USERPROFILE
      29 x86 system directory on RISC
      2a x86 C:\Program Files on RISC
      2b C:\Program Files\Com

      "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
      "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

      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