Drag/drop from TreeView (not in ActionsPane) to Excel Worksheet ?
Hi,
Is it possible to drag from a TreeView to an excel worksheet where the TreeView was spawned from a click event on a command bar button ? The command bar is created by a VSTO app-level add-in. We are using C#. More specifically, the nodes in the TreeView represent Reports that would appear in the Excel worksheet after they are dragged into it. (We do not want to use an actions pane because we need the TreeView to be application level and we have to make it work in Excel 2003 -- which does not support app-level actions panes or app-level Custom Task Panes). So there are really 2 questions he 1) How do we accomplish the drag drop operation in this scenario ? Especially the drop part. 2) How do we recognize the drop target in such a way that we can read a bunch of metadata (containing cell contents) from perhaps an XML file or some other file to create the report in the Excel spreadsheet ? Is this a dream or can it actually be done ? We greatly appreciate any guidance you could provide. Thanks, Tom Standard & Poor's -- Tom in Denver |
Drag/drop from TreeView (not in ActionsPane) to Excel Worksheet ?
Kinda surprised nobody responded, but I found this article quite helpful:
http://msdn2.microsoft.com/en-us/lib...ontoSupplyData The one thing missing is I don't know what Excel event to use if there is no workbook open. The SheetChange event covers the case when there is a workbook open. -- Tom in Denver "TomInDenver" wrote: Hi, Is it possible to drag from a TreeView to an excel worksheet where the TreeView was spawned from a click event on a command bar button ? The command bar is created by a VSTO app-level add-in. We are using C#. More specifically, the nodes in the TreeView represent Reports that would appear in the Excel worksheet after they are dragged into it. (We do not want to use an actions pane because we need the TreeView to be application level and we have to make it work in Excel 2003 -- which does not support app-level actions panes or app-level Custom Task Panes). So there are really 2 questions he 1) How do we accomplish the drag drop operation in this scenario ? Especially the drop part. 2) How do we recognize the drop target in such a way that we can read a bunch of metadata (containing cell contents) from perhaps an XML file or some other file to create the report in the Excel spreadsheet ? Is this a dream or can it actually be done ? We greatly appreciate any guidance you could provide. Thanks, Tom Standard & Poor's -- Tom in Denver |
All times are GMT +1. The time now is 04:13 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com