property Element.ElementFormat as String
Specifies the way the control shows the parts of the element.

TypeDescription
String A String format that specified the CRD format to arrange the parts of the element.
By default, the ElementFormat property is empty. Use the ElementFormat property to arrange in a different way the parts of the element. If the ElementFormat property is empty, the format of the elements is specified by the control's ElementFormat property. In other words, all elements can be formatted the same way using the control's ElementFormat property or separate way using the Element's ElementFormat property. The DrawPartsOrder property defines the order of the parts the elements display. The DrawPartsOrder property has no effect if the ElementFormat property is set.  

The know parts of the element are:

The parts of the elements must be included between "" in order to be recognized by the CRD format.

For instance:

The following samples show how you can display the element's checkbox next to the Command button.

VBA (MS Access, Excell...)

With SwimLane1
	With .Elements
		With .InsertControl("Forms.CommandButton.1")
			.ElementFormat = """check"":18,""client"""
			.Object.Caption = "command"
			.ShowCheckBox = True
			.Height = 48
			.Width = 128
		End With
	End With
End With

VB6

With SwimLane1
	With .Elements
		With .InsertControl("Forms.CommandButton.1")
			.ElementFormat = """check"":18,""client"""
			.Object.Caption = "command"
			.ShowCheckBox = True
			.Height = 48
			.Width = 128
		End With
	End With
End With

VB.NET

With Exswimlane1
	With .Elements
		With .InsertControl("Forms.CommandButton.1")
			.ElementFormat = """check"":18,""client"""
			.Object.Caption = "command"
			.ShowCheckBox = True
			.Height = 48
			.Width = 128
		End With
	End With
End With

VB.NET for /COM

With AxSwimLane1
	With .Elements
		With .InsertControl("Forms.CommandButton.1")
			.ElementFormat = """check"":18,""client"""
			.Object.Caption = "command"
			.ShowCheckBox = True
			.Height = 48
			.Width = 128
		End With
	End With
End With

C++

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXSWIMLANELib' for the library: 'ExSwimLane 1.0 Control Library'

	#import <ExSwimLane.dll>
	using namespace EXSWIMLANELib;
*/
EXSWIMLANELib::ISwimLanePtr spSwimLane1 = GetDlgItem(IDC_SWIMLANE1)->GetControlUnknown();
EXSWIMLANELib::IElementsPtr var_Elements = spSwimLane1->GetElements();
	EXSWIMLANELib::IElementPtr var_Element = var_Elements->InsertControl("Forms.CommandButton.1",vtMissing,vtMissing,vtMissing);
		var_Element->PutElementFormat(L"\"check\":18,\"client\"");
		/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'MSForms' for the library: 'Microsoft Forms 2.0 Object Library'

	#import <FM20.DLL>
*/
		((MSForms::ICommandButtonPtr)(var_Element->GetObject()))->PutCaption(L"command");
		var_Element->PutShowCheckBox(VARIANT_TRUE);
		var_Element->PutHeight(48);
		var_Element->PutWidth(128);

C++ Builder

Exswimlanelib_tlb::IElementsPtr var_Elements = SwimLane1->Elements;
	Exswimlanelib_tlb::IElementPtr var_Element = var_Elements->InsertControl(TVariant("Forms.CommandButton.1"),TNoParam(),TNoParam(),TNoParam());
		var_Element->ElementFormat = L"\"check\":18,\"client\"";
		(IDispatch*)var_Element->Object->Caption = L"command";
		var_Element->ShowCheckBox = true;
		var_Element->Height = 48;
		var_Element->Width = 128;

C#

exontrol.EXSWIMLANELib.Elements var_Elements = exswimlane1.Elements;
	exontrol.EXSWIMLANELib.Element var_Element = var_Elements.InsertControl("Forms.CommandButton.1",null,null,null);
		var_Element.ElementFormat = "\"check\":18,\"client\"";
		// Add 'Microsoft Forms 2.0 Object Library' reference to your project.
		(var_Element.Object as MSForms.CommandButton).Caption = "command";
		var_Element.ShowCheckBox = true;
		var_Element.Height = 48;
		var_Element.Width = 128;

JavaScript

<OBJECT classid="clsid:AFA73FCE-6609-4062-AE6A-4BAD6D96A025" id="SwimLane1"></OBJECT>

<SCRIPT LANGUAGE="JScript">
	var var_Elements = SwimLane1.Elements;
		var var_Element = var_Elements.InsertControl("Forms.CommandButton.1",null,null,null);
			var_Element.ElementFormat = "\"check\":18,\"client\"";
			var_Element.Object.Caption = "command";
			var_Element.ShowCheckBox = true;
			var_Element.Height = 48;
			var_Element.Width = 128;
</SCRIPT>

C# for /COM

EXSWIMLANELib.Elements var_Elements = axSwimLane1.Elements;
	EXSWIMLANELib.Element var_Element = var_Elements.InsertControl("Forms.CommandButton.1",null,null,null);
		var_Element.ElementFormat = "\"check\":18,\"client\"";
		// Add 'Microsoft Forms 2.0 Object Library' reference to your project.
		(var_Element.Object as MSForms.CommandButton).Caption = "command";
		var_Element.ShowCheckBox = true;
		var_Element.Height = 48;
		var_Element.Width = 128;

X++ (Dynamics Ax 2009)

public void init()
{
	COM com_Element,com_Elements,com_Object;
	anytype var_Element,var_Elements,var_Object;
	;

	super();

	var_Elements = exswimlane1.Elements(); com_Elements = var_Elements;
		var_Element = com_Elements.InsertControl("Forms.CommandButton.1"); com_Element = var_Element;
			com_Element.ElementFormat("\"check\":18,\"client\"");
			var_Object = COM::createFromObject(com_Element.Object()); com_Object = var_Object;
			com_Object.Caption("command");
			com_Element.ShowCheckBox(true);
			com_Element.Height(48);
			com_Element.Width(128);
}

Delphi 8 (.NET only)

with AxSwimLane1 do
begin
	with Elements do
	begin
		with InsertControl('Forms.CommandButton.1',Nil,Nil,Nil) do
		begin
			ElementFormat := '"check":18,"client"';
			(Object as MSForms.CommandButton).Caption := 'command';
			ShowCheckBox := True;
			Height := 48;
			Width := 128;
		end;
	end;
end

Delphi (standard)

with SwimLane1 do
begin
	with Elements do
	begin
		with InsertControl('Forms.CommandButton.1',Null,Null,Null) do
		begin
			ElementFormat := '"check":18,"client"';
			(IUnknown(Object) as MSForms_TLB.CommandButton).Caption := 'command';
			ShowCheckBox := True;
			Height := 48;
			Width := 128;
		end;
	end;
end

VFP

with thisform.SwimLane1
	with .Elements
		with .InsertControl("Forms.CommandButton.1")
			.ElementFormat = ""+chr(34)+"check"+chr(34)+":18,"+chr(34)+"client"+chr(34)+""
			.Object.Caption = "command"
			.ShowCheckBox = .T.
			.Height = 48
			.Width = 128
		endwith
	endwith
endwith

dBASE Plus

local oSwimLane,var_Element,var_Elements

oSwimLane = form.Activex1.nativeObject
var_Elements = oSwimLane.Elements
	var_Element = var_Elements.InsertControl("Forms.CommandButton.1")
		var_Element.ElementFormat = "" + ["] + "check" + ["] + ":18," + ["] + "client" + ["] + ""
		var_Element.Object.Caption = "command"
		var_Element.ShowCheckBox = true
		var_Element.Height = 48
		var_Element.Width = 128

XBasic (Alpha Five)

Dim oSwimLane as P
Dim var_Element as P
Dim var_Elements as P

oSwimLane = topparent:CONTROL_ACTIVEX1.activex
var_Elements = oSwimLane.Elements
	var_Element = var_Elements.InsertControl("Forms.CommandButton.1")
		var_Element.ElementFormat = "\"check\":18,\"client\""
		var_Element.Object.Caption = "command"
		var_Element.ShowCheckBox = .t.
		var_Element.Height = 48
		var_Element.Width = 128

Visual Objects

local var_Element as IElement
local var_Elements as IElements

var_Elements := oDCOCX_Exontrol1:Elements
	var_Element := var_Elements:InsertControl("Forms.CommandButton.1",nil,nil,nil)
		var_Element:ElementFormat := "" + CHR(34) + "check" + CHR(34) + ":18," + CHR(34) + "client" + CHR(34) + ""
		// Generate Source for 'Microsoft Forms 2.0 Object Library' server from Tools\Automation Server...
		ICommandButton{var_Element:Object}:Caption := "command"
		var_Element:ShowCheckBox := true
		var_Element:Height := 48
		var_Element:Width := 128

PowerBuilder

OleObject oSwimLane,var_Element,var_Elements

oSwimLane = ole_1.Object
var_Elements = oSwimLane.Elements
	var_Element = var_Elements.InsertControl("Forms.CommandButton.1")
		var_Element.ElementFormat = "" + CHAR(34) + "check" + CHAR(34) + ":18," + CHAR(34) + "client" + CHAR(34) + ""
		var_Element.Object.Caption = "command"
		var_Element.ShowCheckBox = true
		var_Element.Height = 48
		var_Element.Width = 128

Visual DataFlex

Procedure OnCreate
	Forward Send OnCreate
	Variant voElements
	Get ComElements to voElements
	Handle hoElements
	Get Create (RefClass(cComElements)) to hoElements
	Set pvComObject of hoElements to voElements
		Variant voElement
		Get ComInsertControl of hoElements "Forms.CommandButton.1" Nothing Nothing Nothing to voElement
		Handle hoElement
		Get Create (RefClass(cComElement)) to hoElement
		Set pvComObject of hoElement to voElement
			Set ComElementFormat of hoElement to ""check":18,"client""
			Variant voCommandButton
			Get ComObject of hoElement to voCommandButton
			Handle hoCommandButton
			Get Create (RefClass(cComCommandButton)) to hoCommandButton
			Set pvComObject of hoCommandButton to voCommandButton
				Set ComCaption of hoCommandButton to "command"
			Send Destroy to hoCommandButton
			Set ComShowCheckBox of hoElement to True
			Set ComHeight of hoElement to 48
			Set ComWidth of hoElement to 128
		Send Destroy to hoElement
	Send Destroy to hoElements
End_Procedure

XBase++

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oElement
	LOCAL oElements
	LOCAL oSwimLane

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oSwimLane := XbpActiveXControl():new( oForm:drawingArea )
	oSwimLane:CLSID  := "Exontrol.SwimLane.1" /*{AFA73FCE-6609-4062-AE6A-4BAD6D96A025}*/
	oSwimLane:create(,, {10,60},{610,370} )

		oElements := oSwimLane:Elements()
			oElement := oElements:InsertControl("Forms.CommandButton.1")
				oElement:ElementFormat := "" + CHR(34) + "check" + CHR(34) + ":18," + CHR(34) + "client" + CHR(34) + ""
				oElement:Object():Caption := "command"
				oElement:ShowCheckBox := .T.
				oElement:Height := 48
				oElement:Width := 128

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN