public bool OpenLogFile(out string fileName)
{
fileName = null;
bool opened = false;
var dlg = new OpenFileDialog();
try
{
dlg.InitialDirectory = _fileLocation;
dlg.Filter = "Log Files|AW*.log";
dlg.FilterIndex = 1;
dlg.RestoreDirectory = true;
if (DialogResult.OK == dlg.ShowDialog())
{
fileName = dlg.FileName;
//fs = new FileStream(dlg.FileName, FileMode.Open, FileAccess.Read);
opened = true;
}
}
catch (Exception e)
{
LogManager.Error(e);
}
return opened;
}