I need to know when my editor is selected, so I have done the items in this post (Answer I posted for someone else's question, worked for them, doesn't for me)
How to get the current editor in VS?
I believe the __VSFPROPID.VSFPROPID_guidEditorType returns the IVsEditorFactory GUID. My Factory definition looks like:
My SelectionEventsHandler is exactly as I posted in the previously mentioned thread.
The first call to get the ItemID grabs the correct value. The second call to get the EditorTypeGuid fails and returns Nothing. The error code (result2) is Microsoft.VisualStudio.VSConstants.DISP_E_MEMBERNOTFOUND
I'm using the VsShell Isolated, on Studio 2008.
How to get the current editor in VS?
I believe the __VSFPROPID.VSFPROPID_guidEditorType returns the IVsEditorFactory GUID. My Factory definition looks like:
| <Guid(GuidList.myGUIDString)> _ |
| Public Class MyFactory |
| Implements IVsEditorFactory, IDisposable |
My SelectionEventsHandler is exactly as I posted in the previously mentioned thread.
| Dim result As Integer = myFrame.GetProperty(__VSFPROPID.VSFPROPID_ItemID, value) |
| Dim result2 As Integer = myFrame.GetProperty(__VSFPROPID.VSFPROPID_guidEditorType, guidEditorType) |
The first call to get the ItemID grabs the correct value. The second call to get the EditorTypeGuid fails and returns Nothing. The error code (result2) is Microsoft.VisualStudio.VSConstants.DISP_E_MEMBERNOTFOUND
I'm using the VsShell Isolated, on Studio 2008.