L
LunchBox
I have a program that launches a dial up form so that a person can choose
which dial up entry to use. The problem I have is that I need the parent
form to wait until the dial up is connected before continuing on with the
tasks that require the connection. I'm trying to use threads to do this,
but I really am not very experienced with them
This is the event that is called when the person needs to synchronize:
private void menuItemSynchronize_Click(object sender, System.EventArgs e)
{
try
{
this.Cursor = System.Windows.Forms.Cursors.AppStarting;
if(!connected())//determines if the computer is already online
{
Thread conn = new Thread(new ThreadStart(connectToCBE));
}
doTasks();
This the method that launches the dial up dialog box:
private void connectToServer()
{
r.ShowDialog(this);//r is the dial up class
r.Dispose();
while(r.Status)// r.Status checks to see if r is connected
Thread.Sleep(0);
}
Any help is appreciated.
which dial up entry to use. The problem I have is that I need the parent
form to wait until the dial up is connected before continuing on with the
tasks that require the connection. I'm trying to use threads to do this,
but I really am not very experienced with them
This is the event that is called when the person needs to synchronize:
private void menuItemSynchronize_Click(object sender, System.EventArgs e)
{
try
{
this.Cursor = System.Windows.Forms.Cursors.AppStarting;
if(!connected())//determines if the computer is already online
{
Thread conn = new Thread(new ThreadStart(connectToCBE));
}
doTasks();
This the method that launches the dial up dialog box:
private void connectToServer()
{
r.ShowDialog(this);//r is the dial up class
r.Dispose();
while(r.Status)// r.Status checks to see if r is connected
Thread.Sleep(0);
}
Any help is appreciated.