Table of Contents

Property FormDesigner

Namespace
Alternet.FormDesigner.Wpf.Outline
Assembly
Alternet.FormDesigner.Wpf.v10.dll

FormDesigner

Gets or sets IFormDesignerControl bound to this outline control.

public IFormDesignerControl FormDesigner { get; set; }

Property Value

IFormDesignerControl

Examples

Here is how to use a FormDesigner in the C# code:

using Alternet.FormDesigner.Wpf;
using Alternet.FormDesigner.Wpf.Outline;
using Alternet.FormDesigner.Wpf.Toolbox;

public partial class MainWindow : Window
{
    private void Window_Loaded(object sender, RoutedEventArgs e)
    {
        var formDesigner = new FormDesignerControl();
        formDesigner.AutoSaveToSource = false;

        var toolboxControl = new ToolboxControl();
        toolboxControl.FormDesigner = formDesigner;

        var outlineControl = new OutlineControl();
        outlineControl.FormDesigner = formDesigner;
        outlineControl.Toolbox = toolboxControl;
    }
}

Here is how to use a FormDesigner in the Visual Basic code:

Imports Alternet.FormDesigner.Wpf
Imports Alternet.FormDesigner.Wpf.Outline
Imports Alternet.FormDesigner.Wpf.Toolbox

Partial Public Class MainWindow
    Inherits Window
    Private Sub Window_Loaded(ByVal sender As Object, ByVal e As RoutedEventArgs)
        Dim formDesigner = New FormDesignerControl()
        formDesigner.AutoSaveToSource = False

        Dim toolboxControl = New ToolboxControl()
        toolboxControl.FormDesigner = formDesigner

        Dim outlineControl = New OutlineControl()
        outlineControl.FormDesigner = formDesigner
        outlineControl.Toolbox = toolboxControl
    End Sub
End Class

Remarks

You can associate the Form designer with the OutlineControl object by setting FormDesigner property. This allows users to place components on the designer's surface, view its logical structure, and find controls that are deeply nested or hidden.