none
Drag-n-Drop DataObject as Object of Class : HierarchyNode RRS feed

  • General discussion

  • Hi,

     

    Can you please help me to use drag-n-drop functionality with HierarchyWindows?

     

    I am using custom node and have Tag as Object of each node....and When I try to drag and drop using

    IVsHierarchyDropDataSource2 and while using that...I need to pass dataobject as output and dragsource...

    But this object is a reference type variable,...and the base datatype if IDataObject.

     

    So, How to use it and whre can I find some help...as I am new to VSX.....

     

    Your help will be highly appreciated, if you could provide a sample in the form of solution...

     

    Thank you allll!!!!!!!!!!! :-)

     

    Regards

    Thursday, March 20, 2008 6:37 AM

All replies

  • Where to begin... this seems like a very broad question. What might be better is to post some specific code segments you are having trouble figuring out and asking some more specific questions. Otherwise it's hard to know how to begin answering this.
    Thursday, March 20, 2008 2:38 PM
  • Hi Rahul,

    I agree with Justin - there is not enough information about your problem. What kind of extensibility do you use - add-in or package? Could you please describe what do you working on?
    Friday, March 21, 2008 10:02 PM
    Moderator
  • Hi Guys,

     

    I am using VSIP(Package) for this....

     

    Scenario:

    We have created a new hierarchywindow which contains some dataItems in tree structure. We do have some editors which are helpful to edit the items within their specific editor...and some editors can have other items to be refered and we need drag-n-drop over here.

     

    As prevoiusly, we were using TreeView windows control it was working fine, and when we implemented this HierarchyWindow, we are not able to implement this and this became a critical problem for us.

     

    Requirement:

    we need to have our new solution explorer to enable drag-n-drop between the HierarchyWindow and the user controls of the editor..

     

    So, after going through with MSDN, I found two interfaces

    IVsHierarchyDropDataTarget,

    IVsHierarchyDropDataSource2

     

    Which needs to be inherited for the implementation.

     

    Your help will be higly appreciated.

     

    If you need something else, please feel free to contact me.

     

    Thanks

    Rahul Goel

     

     

    Monday, March 24, 2008 4:35 AM
  • Hi Rahul,

     

    I'm still a bit unclear as to what exactly you are attempting to accomplish.

     

    Where does this drag operation start, and what window are you attempting to drop to?

     

    When you say HierachyWindow, are you reusing the VsUIHierarchyWindow in a custom toolwindow implementation? And are you attempting to drag items from this window to somewhere else? If so, where?

     

    Or are you attempting to drag items from somewhere else to this toolwindow?

     

    Sincerely,

    Monday, March 24, 2008 7:16 PM
    Moderator
  • We are changing the issue type to “Comment” because you have not followed up with the necessary information. If you have more time to look at the issue and provide more information, please feel free to change the issue type back to “Question” by editing your initial post and changing the radio button at the top of the post editor window. If the issue is resolved, we will appreciate it if you can share the solution so that the answer can be found and used by other community members having similar questions. 

    Thank you! 
    Monday, March 31, 2008 3:14 AM