Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / Extensibility / December 2005

Tip: Looking for answers? Try searching our database.

Handling QueryStatus for IOLECommandTarget

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Kajal  Sinha - 25 Nov 2005 07:32 GMT
Hi Thomas,
I am implementing interface IOleCommandTarget on MyProjectNode
(Project class name). The method QueryStatus is not doing anything. but
just returning VsConstants.S_OK.

Now in the vs.net 2005 exp hive i am unable to execute any of the menu
command if i ve set the focus on my custom code editor.
the menus appears and after click nothing happens. please help.

Thanks
Kajal Sinha
Ed Dore [MSFT] - 25 Nov 2005 23:18 GMT
Hi Kajal,

You need to set the cmdf member of the appropriate OLECMD elements passed
via the OLECMD[] argument. There are several C# sample packages (one of
which is the BasicEditor sample), that have IOleCommandTarget
implementations. You might want to review the QueryStatus implementations in
those samples to get an idea of how to go about propertly implementing your
QueryStatus. Ideally, you should not be returning S_OK from your QueryStatus
implementation unless the command(s) in question is one that you want to
support.

Sincerely,
Ed Dore [MSFT]

This post is 'AS IS' with no warranties and confers no rights.
jimmy - 08 Dec 2005 17:56 GMT
Thanks Ed. its working now.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.