/***打开文件***/#region/***打开文件***/
/**//// <summary>
/// 运行或打开文件
/// </summary>
public void Run()
{
if (this._lst.SelectedItems.Count != 1 || DirPath == "")
return;
ListViewItem item = this._lst.SelectedItems[0];
string fileName = DirPath + item.Text;
try
{
System.Diagnostics.Process.Start(fileName);
}
catch (System.ComponentModel.Win32Exception ex)
{
MessageBox.Show(ex.Message);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
#endregion
/**//// <summary>
/// 运行或打开文件
/// </summary>
public void Run()
{
if (this._lst.SelectedItems.Count != 1 || DirPath == "")
return;
ListViewItem item = this._lst.SelectedItems[0];
string fileName = DirPath + item.Text;
try
{
System.Diagnostics.Process.Start(fileName);
}
catch (System.ComponentModel.Win32Exception ex)
{
MessageBox.Show(ex.Message);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
#endregion