Can you try doing something like this:
namespace WindowsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
if (File.Exists(@"C:\FOO.TXT"))
{
MessageBox.Show("File Exists!");
DoSomething();
}
else
{
this.Hide();
using (Form2 frm = new Form2())
{
if (frm.ShowDialog() == DialogResult.OK)
{
DoSomethingElse();
}
}
this.Show();
}
}
void DoSomething() { }
void DoSomethingElse() { }
}
}
I apologize for all the generic names, I'm on my lunch break from work.
