Click to See Complete Forum and Search --> : How do I make two Forms running at a time ?


M.Anand
February 4th, 1999, 11:03 PM
I have some process happening in Form1 and I want to display another form above this form.This is similar to the Task Manager. When I kill a process , the Clock Screen appears and at the same time the Process is killed.


If I try to start or stop a service and at the same time try to run a modeless form above that,I couldn't accomplish both at the same time


This is the code


Form2.Timer.Enabled = True

Form2.Timer.Interval = 500


Form1.StartService()


// Stop the Timer


Form2_Timer

{


// Keep changing the Clock Images


}


BUT the Timer doesn't happen until StartService function is returned


Thanks

Anand

Vinayak Sapre
February 14th, 1999, 08:59 AM
If I understand correctly u'r running a lengthy process in Form1. Form2 has a timer control with timer event doing some GUI work.

If this is correct then solution is simple.

Solution 1 : In StartService after every one or two statements add doevnts statement. This allows all Forms to refresh.

Solution2 : Do it hardway run StartService in another thread.