Color scheme: Dark
You are here: start » en » Documentation » Microsoft Access development tools » WKL Forms Object Library » Layout » WklDrawer

WklDrawer

A panel on the right edge of a form that opens beside a list: the list becomes narrower, the panel shows an edit form or details, and a bar between them lets the user drag the width.

Get started

Common tasks

Visual aid

┌──────────────────────────────────────────────┬──┬──────────────────────────┐
│ Customers                                    │⋮ │ Edit customer          ③ │
│ Adams    Boston                              │× │ Company [Adams        ]  │
│ Baker    Chicago                           ① │②│ City    [Boston       ]  │
│ …                                            │⋮ │                [ OK ]    │
└──────────────────────────────────────────────┴──┴──────────────────────────┘
RegionMeaning
①The controls beside the panel (BesideControls, empty: found by position). They become narrower while the panel is open and take the whole width when it closes.
②The WklDrawer control itself: the bar with grip dots and the close button (CloseButton). The user drags it (Resizable) or moves it with the arrow keys.
③The subform control named in Content. Open "frmCustomerEdit" sets its source object and shows it; anchored controls inside follow the width (AnchorContent).

Key features

  • One panel, many contents. Open takes the name of a form (or Table.x, Query.x) and shows it in the subform control; Close, Toggle and IsOpen complete it. BeforeOpen and BeforeClose can cancel, AfterOpen, Closed and AfterResize follow.
  • The width belongs to the content. A width the user dragged to is remembered per content and Windows user, then the width designed for that content in Widths, then Width. MinWidth, MaxWidth and MinBeside limit it; in a narrow window the controls beside keep MinBeside.
  • Anchors that work inside the panel. Access applies the anchors of a page's controls only when the window changes size, not when the panel's width changes; the drawer applies them at once (AnchorContent).
  • Fills to the right edge. With FillForm the panel reaches the right edge of the visible form and follows it when the window changes size.
  • Like Access. The focus goes into the content when the panel opens; Esc closes it while the record there is unchanged (CloseOnEscape); the bar is a tab stop, a Thumb with RangeValue and ExpandCollapse for screen readers.

Core concepts

The drawer arranges the controls of its own section in form view only and computes every arrangement from the design: the area is the rectangle from the left edge of the controls beside to the right edge of the panel (or of the visible form with FillForm). Open, the panel takes its width from the right, the bar stands left of it and the controls beside fill the rest; closed, the bar and the panel are hidden and the controls beside take the whole area. Remembered widths live in the table USysWklLayout of the database, as those of WklSplitter and WklDockLayout. In design view nothing moves; the designer ([...] in the row Custom) shows which controls the drawer found.

Administration

Troubleshooting

None

For developers

en/wiki/msaccess/comctl/layout/drawer/start.txt · Last modified: by Wolfgang van der Stille