public static string GetListViewText(ListView lv, int i) { if (lv.InvokeRequired) { GetListViewTextDelegate msgCallback = new GetListViewTextDelegate(WindowFormDelegate.GetListViewText); object result=lv.Invoke(msgCallback, new object[] {lv, i }); return result.ToString(); } else { return lv.Items[i].Text.Trim(); } }
public static string GetListViewText(ListView lv, int i) { if (lv.InvokeRequired) { GetListViewTextDelegate msgCallback = new GetListViewTextDelegate(WindowFormDelegate.GetListViewText); object result = lv.Invoke(msgCallback, new object[] { lv, i }); return(result.ToString()); } else { return(lv.Items[i].Text.Trim()); } }