Description

Top Left

NumberOfRows

Long Long Long

The position of the top edge of the toolbar from the top of the screen given in pixels.

The position of the left side of the toolbar from the left edge of the screen given in pixels.

The number of rows that the toolbar buttons should be distributed over. If this is set to more than the number of buttons on the toolbar, this parameter will be ignored.

This code sample shows how to use the Float method by floating the AutoCAD Draw toolbar to the top-left corner of the screen:

Public Sub FloatDrawToolbar() Dim objToolBarDraw As AcadToolbar

Set objToolBarDraw = _

ThisDrawing.Application.MenuGroups.Item("ACAD").Toolbars.Item("Draw")

objToolBarDraw.Float 0, 0, 3 End Sub

Figure 16-11 shows the floating toolbar. Note that the toolbar lies outside the AutoCAD window and is split over three rows. To dock a toolbar, use the Dock method.

ToolbarObject.Dock DockStatus

Table 16-17 shows the Dock method's parameter.

Table 16-17. The Dock Method's Parameter

Figure 16-11. Floating a toolbar

Table 16-17. The Dock Method's Parameter

Name

Data Type

Description

DockStatus

Long

This specifies which edge of the window to dock to. It must be one of the AcToolbarDockStatus constants presented in Table 16-18.

Table 16-18 contains the AcToolbarDockStatus constants.

Table 16-18. The AcToolbarDockStatus Constants

Constant

Value

Was this article helpful?

0 0

Post a comment