Solved

Custom Properties for "virtual folders" in windows explorer

Posted on 1998-07-26
2
410 Views
Last Modified: 2013-12-03
Experts Exchange,

I am developing an application that includes adding a "virtual folder" to the windows explorer tree at the same level as A:\, C:\, D:\, Control Panel etc…., by using the Shell Library Interfaces.

To this "virtual folder" have I attached a context menu handler, and by registering the default flag SFGAO_HASPROPSHEET for this folder, have I managed to enable the "Properties" menu option in the context menu. To this "properties" menu option is my goal to attach custom designed property pages, including a custom first page.

My problem is that when I select the "properties" menu option I get a message from the system telling me that " the needed methods for the object are not available". I have tried to solve the problem with the "IshellPropSheetExt" interface, but as i understand is this interface only for adding extra property pages to standard file property pages.

So, my questions are how do I implement the interface for custom designed property pages, including a custom first page, attached to a "virtual folder" in the windows explorer? As always is there any good sample that shows this mechanism?

I have noticed that in the file Shlguid.h is there Shell Library Interfaces defined but not documented at all. There is for instance an interface ID called "IID_IPropSheetPage". Is it perhaps this interface i should use, and if so where can i find documents that describe this. Is it perhaps interfaces only known by Microsoft?

Best regards

0
Comment
Question by:StefanJo
2 Comments
 

Author Comment

by:StefanJo
ID: 1411064
Adjusted points to 200
0
 

Accepted Solution

by:
DmitryC earned 200 total points
ID: 1411065
Hi,

In case when namespace extension (AKA virtual folder) has got SFGAO_HASPROPSHEET bit set, shell looks for IPropSheetExt CLSID's in the following location:
HKEY_CLASSES_ROOT\CLSID\{your virtual folder CLSID}\ShellEx\PropertySheetHandlers\{your propsheetext CLSID}

It asks to create instance of {your propsheetext CLSID} with IShellExtInit interface. After the Initialize call succeeds it QueryInterfase's it for IPropSheetExt.

Also, try to look at your IContextMenu's InvokeCommand calls. It is possible that shell will call it with "properties" verb and ask to display PropertySheet dialog by yourself.

My extension is rooted from Desktop and I tried to put it into My Computer (as you did) also - it works fine.

Regards,
Dima
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Method 'OpenReport' of the object Docmd failed 7 30
Handle Exceptions during instantiation 28 415
Is COM supported from Apache 1 53
Where did System.Data.Objects go? 2 27
A theme is a collection of property settings that allow you to define the look of pages and controls, and then apply the look consistently across pages in an application. Themes can be made up of a set of elements: skins, style sheets, images, and o…
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question