/// <summary> /// Adds an item to the ListView for a successfully 'imported' entry. /// </summary> /// <param name="e">The ItemReadEvent object for the entry imported.</param> /// <param name="status">The ImportStatus object for the entry imported.</param> /// <param name="item">The ReportServerItem object that was imported.</param> /// <returns></returns> private ListViewItem AddListViewItem_Success(ItemReadEvent e, ImportStatus status, ReportServerItem item) { ListViewItem oItem = new ListViewItem(item.Name); oItem.Tag = item; oItem.SubItems.Add(item.Path); oItem.SubItems.Add(""); oItem.Checked = true; return oItem; }
/// <summary> /// Adds an item to the ListView for an entry that was not successfully imported from disk. /// </summary> /// <param name="e">The ItemReadEvent object for the entry that failed to import from disk.</param> /// <param name="status">The ImportStatus object for the entry that failed to import from disk.</param> /// <returns></returns> private ListViewItem AddListViewItem_ImportFailed(ItemReadEvent e, ImportStatus status) { string name = this.mFileSystem.Path.GetFileNameWithoutExtension(e.FileName); ListViewItem oItem = new ListViewItem(name); oItem.Checked = false; oItem.ForeColor = Color.Red; //oItem.Tag = e.FileName; oItem.SubItems.Add(e.Path); oItem.SubItems.Add(status.Error.Message); return oItem; }