combit List & Label 24 - .NET Online Web Help
Edit and Extend the Designer
Programming Introduction > Other Important Concepts > Edit and Extend the Designer

The Designer is not a "Black Box” for the application, but can be manipulated in many ways. Besides disabling functions and menu items, user-specific elements can be added that move calculations, actions or outputs to the function logic.

 

Menu Items, Objects and Functions

Starting point for Designer restrictions is the DesignerWorkspace property of the ListLabel object. In the following table the properties listed can be used to restrict the Designer:

Property Function
ProhibitedActions This property's purpose is to remove single menu items from the Designer.
ProhibitedFunctions This property's purpose is to remove single functions from the Designer.
ReadOnlyObjects This property's purpose is to prevent objects' editability in the Designer. The objects are still visible; however they can't be edited or deleted within the Designer.

The following example shows how the Designer can be adjusted so no new project can be created. In addition the function ProjectPath$ will be removed and the object "Demo” is prevented from being edited:

ListLabel LL = new ListLabel();
LL.DataSource = CreateDataSet();

LL.DesignerWorkspace.ProhibitedActions.Add(LlDesignerAction.FileNew);
LL.DesignerWorkspace.ProhibitedFunctions.Add("ProjectPath$");
LL.DesignerWorkspace.ReadOnlyObjects.Add("Demo");

LL.Design();
LL.Dispose();
Dim LL As New ListLabel()
LL.DataSource = CreateDataSet()

LL.DesignerWorkspace.ProhibitedActions.Add(LlDesignerAction.FileNew)
LL.DesignerWorkspace.ProhibitedFunctions.Add("ProjectPath$")
LL.DesignerWorkspace.ReadOnlyObjects.Add("Demo")

LL.Design()
LL.Dispose() 

 

Extend Designer

The Designer can be extended by user-specific functions (DesignerFunctions), objects (DesignerObjects) and actions (DesignerActions). User-specific functions can be used to move more complex calculations to the application or add functions which are not covered by the Designer by default. Examples for own objects or actions as well as another own function are shown in the .NET sample Designer Extension Sample.