Adds a new dockable pane to the Revit user interface.
Namespace: Autodesk.Revit.UIAssembly: RevitAPIUI (in RevitAPIUI.dll) Version: 26.4.0.0 (26.4.0.0)
Syntax
C#
public void RegisterDockablePane(
DockablePaneId id,
string title,
IDockablePaneProvider provider
)
Parameters
- id DockablePaneId
- Unique identifier for the new pane.
- title String
- String to use for the pane caption.
- provider IDockablePaneProvider
- Your add-in's implementation of the IDockablePaneProvider interface.
Exceptions
| Exception | Condition |
|---|
| ArgumentException | Thrown if a dockable pane with identifier %id% has already been registered. |
Example
C#
public Result OnStartup(UIControlledApplication application)
{
PaneProvider prov = new PaneProvider();
DockablePaneId id = new DockablePaneId(Guid.NewGuid());
application.RegisterDockablePane(id, "test", prov);
return Result.Succeeded;
}
VB
Public Function OnStartup(application As UIControlledApplication) As Result Implements IExternalApplication.OnStartup
Dim prov As New PaneProvider()
Dim id As New DockablePaneId(Guid.NewGuid())
application.RegisterDockablePane(id, "test", prov)
Return Result.Succeeded
End Function
See Also
Reference