Type | Description | |||
Boolean | A boolean expression that specifies whether the control is drawn from right to left or from left to right. |
Changing the RightToLeft property on True does the following:
The following screen shot shows how the control looks if the RightToLeft property is True:
(By default) Changing the RightToLeft property on False does the following:
The following screen shot shows how the control looks if the RightToLeft property is False:
The following VB sample shows how to change the order of the columns from right to leftWith Tree1 .BeginUpdate .ScrollBars = exDisableBoth .LinesAtRoot = exLinesAtRoot With .Columns.Add("P1") .Def(exCellHasCheckBox) = True .PartialCheck = True End With With .Items h = .AddItem("Root") .InsertItem h,0,"Child 1" .InsertItem h,0,"Child 2" .ExpandItem(h) = True End With .RightToLeft = True .EndUpdate End WithThe following VB.NET sample shows how to change the order of the columns from right to left
Dim h With AxTree1 .BeginUpdate .ScrollBars = EXTREELib.ScrollBarsEnum.exDisableBoth .LinesAtRoot = EXTREELib.LinesAtRootEnum.exLinesAtRoot With .Columns.Add("P1") .Def(EXTREELib.DefColumnEnum.exCellHasCheckBox) = True .PartialCheck = True End With With .Items h = .AddItem("Root") .InsertItem h,0,"Child 1" .InsertItem h,0,"Child 2" .ExpandItem(h) = True End With .RightToLeft = True .EndUpdate End WithThe following C++ sample shows how to change the order of the columns from right to left
/* Copy and paste the following directives to your header file as it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library' #import <ExTree.dll> using namespace EXTREELib; */ EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown(); spTree1->BeginUpdate(); spTree1->PutScrollBars(EXTREELib::exDisableBoth); spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot); EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"P1"))); var_Column->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE); var_Column->PutPartialCheck(VARIANT_TRUE); EXTREELib::IItemsPtr var_Items = spTree1->GetItems(); long h = var_Items->AddItem("Root"); var_Items->InsertItem(h,long(0),"Child 1"); var_Items->InsertItem(h,long(0),"Child 2"); var_Items->PutExpandItem(h,VARIANT_TRUE); spTree1->PutRightToLeft(VARIANT_TRUE); spTree1->EndUpdate();The following C# sample shows how to change the order of the columns from right to left
axTree1.BeginUpdate(); axTree1.ScrollBars = EXTREELib.ScrollBarsEnum.exDisableBoth; axTree1.LinesAtRoot = EXTREELib.LinesAtRootEnum.exLinesAtRoot; EXTREELib.Column var_Column = (axTree1.Columns.Add("P1") as EXTREELib.Column); var_Column.set_Def(EXTREELib.DefColumnEnum.exCellHasCheckBox,true); var_Column.PartialCheck = true; EXTREELib.Items var_Items = axTree1.Items; int h = var_Items.AddItem("Root"); var_Items.InsertItem(h,0,"Child 1"); var_Items.InsertItem(h,0,"Child 2"); var_Items.set_ExpandItem(h,true); axTree1.RightToLeft = true; axTree1.EndUpdate();The following VFP sample shows how to change the order of the columns from right to left
with thisform.Tree1 .BeginUpdate .ScrollBars = 15 .LinesAtRoot = -1 with .Columns.Add("P1") .Def(0) = .T. .PartialCheck = .T. endwith with .Items h = .AddItem("Root") .InsertItem(h,0,"Child 1") .InsertItem(h,0,"Child 2") .DefaultItem = h .ExpandItem(0) = .T. endwith .RightToLeft = .T. .EndUpdate endwithThe following Delphi sample shows how to change the order of the columns from right to left
with AxTree1 do begin BeginUpdate(); ScrollBars := EXTREELib.ScrollBarsEnum.exDisableBoth; LinesAtRoot := EXTREELib.LinesAtRootEnum.exLinesAtRoot; with (Columns.Add('P1') as EXTREELib.Column) do begin Def[EXTREELib.DefColumnEnum.exCellHasCheckBox] := TObject(True); PartialCheck := True; end; with Items do begin h := AddItem('Root'); InsertItem(h,TObject(0),'Child 1'); InsertItem(h,TObject(0),'Child 2'); ExpandItem[h] := True; end; RightToLeft := True; EndUpdate(); end