public IList<Item> Items {get;}
Public ReadOnly Property Items As IList(Of Item)
public IList<Item> Items {get;}
Public ReadOnly Property Items As IList(Of Item)
OpenItemDialog addToProjectDialog = new OpenItemDialog(); addToProjectDialog.Title = "Add To Project"; addToProjectDialog.InitialLocation = @"C:\Data\NewYork\Counties\Maps"; addToProjectDialog.MultiSelect = true; addToProjectDialog.Filter = ItemFilters.Composite_Maps_Import; bool? ok = addToMapDialog.ShowDialog(); if (ok == true) { IEnumerable<Item> selectedItems = addToMapDialog.Items; foreach (Item selectedItem in selectedItems) MapFactory.Instance.CreateMapFromItem(selectedItem); }
// cref: OpenItemDialog;ArcGIS.Desktop.Catalog.ItemDialog.Filter // cref: OpenItemDialog;ArcGIS.Desktop.Catalog.ItemDialog.InitialLocation // cref: OpenItemDialog;ArcGIS.Desktop.Catalog.ItemDialog.Title // cref: OpenItemDialog;ArcGIS.Desktop.Catalog.OpenItemDialog #region OpenItemDialog /// Adds a single item to a map OpenItemDialog addToMapDialog = new OpenItemDialog() { Title = "Add To Map", InitialLocation = @"C:\Data\NewYork\Counties\Erie\Streets", Filter = ItemFilters.Composite_AddToMap };
Target Platforms: Windows 11, Windows 10, Windows 8.1