VisDirListBox
Namespace: PPJ.Runtime.Vis
Assembly: PPJ.Runtime.Vis.50 (5.0.0.0)
Displays directories as a Visual Toolchest list.
- C#
- VB.NET
public class VisDirListBox : VisListBoxBase
Public Class VisDirListBox
Inherits VisListBoxBase
Example:
using (var list = new PPJ.Runtime.Vis.VisDirListBox())
{
list.Width = 240;
}
Constructors
VisDirListBox()
Initializes the dir list box and its default behavior.
Methods
FromHandle(handle)
Resolves this control type from a native window handle.
| Parameter | Type | Description |
|---|---|---|
| handle | SalWindowHandle | The native control handle. |
Returns: VisDirListBox. The associated VisDirListBox, or null when no managed control owns the handle.
A handle belonging to a different managed control type causes an InvalidCastException.
GetSelectedDir()
Returns the directory stored by the control's creation and double-click handlers.
Returns: SalString. The value of sCurrentDir.
This is not necessarily the highlighted item. Calling Populate directly does not update the stored value.
OnLostFocus(e)
Clears the selection before raising the base lost-focus event.
| Parameter | Type | Description |
|---|---|---|
| e | EventArgs | The focus event data. |
Populate(dir)
Replaces the list with entries for the specified directory.
| Parameter | Type | Description |
|---|---|---|
| dir | SalString | The directory to display. |
Returns: SalBoolean. False if the directory does not exist; otherwise, the directory-population result.
SetSelectedDir()
Repopulates the list for its highlighted directory.
Returns: SalString. The populated path, or Null if no item is selected or population fails.
Returns the chosen path without updating sCurrentDir; the double-click handler assigns that field.
Implements
| Name | Description |
|---|---|
| ISalControl | |
| ISalListControl | |
| ISalWindow |