To do this, pass the user control to the CustomTaskPaneCollection in your VSTO Add-in by calling one of the Add methods. Instantiate the custom task paneĪfter you create a user control that contains the user interface of the custom task pane, you have to instantiate a CustomTaskPane. If you create the user control at design time, you can use the Windows Forms Designer to construct the user interface of your task pane. You can create the user control at design time or at run time. This user control provides the user interface of your custom task pane. This collection returns a new CustomTaskPane object that you can use to modify the appearance of the task pane and respond to user events.įor more information, see How to: Add a custom task pane to an application.Īll custom task panes that are created by using the Office development tools in Visual Studio contain a UserControl object. Instantiate the custom task pane by passing the user control to the CustomTaskPaneCollection object in your VSTO Add-in. You can create a basic custom task pane in two steps:Ĭreate a user interface for your custom task pane by adding Windows Forms controls to a UserControl object. You can also use the data binding support in Windows Forms to bind a data source to controls on the task pane. You can use the familiar Windows Forms Designer to design the user interface for a custom task pane. The user interface of a custom task pane that you create by using the Office development tools in Visual Studio is based on Windows Forms controls. You can create a VSTO Add-in that displays multiple custom task panes at the same time, and users can control each task pane individually. Users can dock custom task panes to different sides of the application window, or they can drag custom task panes to any location in the window. Custom task panes behave like other task panes in the Microsoft Office system. Users of applications in the Microsoft Office system are already familiar with using task panes such as the Styles and Formatting task pane in Word. You can create a custom task pane quickly by using Visual Studio tools. Benefits of custom task panesĬustom task panes let you integrate your features into a familiar user interface. For more information, see Actions pane overview. The actions pane is part of document-level customizations for Microsoft Office Word and Microsoft Office Excel. A custom task pane differs from the actions pane.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |