Gets or sets the direction the ImageList control scrolls the displayed items.
public Orientation Orientation { get; set; } Public Property Orientation As Orientation An System.Windows.Controls.Orientation enumeration that specifies the direction the ImageList control scrolls the displayed items. Default value is Orientation.Horizontal.
When the value of this property is Orientation.Horizontal, the items are added in the control till all the horizontal space is filled, items then will be added in the next "row" and a vertical scrollbar might become visible and functional.
When the value of this property is Orientation.Vertical, the items are added in the control till all the vertical space is filled, items then will be added in the next "column" and a horizontal scrollbar might become visible and functional.
using Leadtools.Help;using Leadtools.Windows.Controls;using Leadtools;using Leadtools.Codecs;public void ImageList_Orientation(ImageList imageList){// Clear out any items in the image listimageList.Items.Clear();// Create 20 itemsfor (int i = 0; i < 20; i++){// Load the imageint index = i + 1;ImageListItem item = new ImageListItem();item.Text = "item" + index.ToString();// Select every otehr itemif ((i % 2) == 0)item.IsSelected = true;// Add the item to the image listimageList.Items.Add(item);}Array a = Enum.GetValues(typeof(Orientation));foreach (Orientation style in a){imageList.Orientation = style;MessageBox.Show("Orientation = " + style.ToString());}// Set vertical scrolling styleimageList.Orientation = Orientation.Vertical;}
Imports Leadtools.Windows.ControlsImports Leadtools.CodecsImports LeadtoolsPublic Sub ImageList_Orientation(ByVal imageList As ImageList)' Clear out any items in the image listimageList.Items.Clear()' Create 20 itemsFor i As Integer = 0 To 19' Load the imageDim index As Integer = i + 1Dim item As ImageListItem = New ImageListItem()item.Text = "item" & index.ToString()' Select every otehr itemIf (i Mod 2) = 0 Thenitem.IsSelected = TrueEnd If' Add the item to the image listimageList.Items.Add(item)Next iDim a As Array = System.Enum.GetValues(GetType(Orientation))For Each style As Orientation In aimageList.Orientation = styleMessageBox.Show("Orientation = " & style.ToString())Next style' Set vertical scrolling styleimageList.Orientation = Orientation.VerticalEnd Sub
using Leadtools.Help;using Leadtools.Windows.Controls;public void ImageList_Orientation(ImageList imageList){// Clear out any items in the image listimageList.Items.Clear();// Create 20 itemsfor (int i = 0; i < 20; i++){// Load the imageint index = i + 1;ImageListItem item = new ImageListItem();item.Text = "item" + index.ToString();// Select every otehr itemif ((i % 2) == 0)item.IsSelected = true;// Add the item to the image listimageList.Items.Add(item);}Array a = GetValues(typeof(Orientation));foreach (Orientation style in a){imageList.Orientation = style;MessageBox.Show("Orientation = " + style.ToString());}// Set vertical scrolling styleimageList.Orientation = Orientation.Vertical;}
Imports Leadtools.Windows.ControlsPublic Sub ImageList_Orientation(ByVal imageList As ImageList)' Clear out any items in the image listimageList.Items.Clear()' Create 20 itemsFor i As Integer = 0 To 19' Load the imageDim index As Integer = i + 1Dim item As ImageListItem = New ImageListItem()item.Text = "item" & index.ToString()' Select every otehr itemIf (i Mod 2) = 0 Thenitem.IsSelected = TrueEnd If' Add the item to the image listimageList.Items.Add(item)Next iDim a As Array = GetValues(GetType(Orientation))For Each style As Orientation In aimageList.Orientation = styleMessageBox.Show("Orientation = " & style.ToString())Next style' Set vertical scrolling styleimageList.Orientation = Orientation.VerticalEnd Sub
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
