J
Jim
I've got a Main Form that takes a list of files. You click the "Process
Button", it then opens a new "Batch" form which processes the images files
one at a time. Unfortunatley the process takes a bit of time but my code
keeps running, not waiting for the batch to get done. How can I have the
"Main" form wait until the Batch form is finished with it's job, before the
"Main" form sends another job to the "Batch" form?
Sorry for being so wordy.. Still trying to get my mind around this problem.
For Example:
processBatchList()
{
for (batchLoop = 0; batchLoop <= numberOfRowsInDataGrid; ++batchLoop)
{
try
{
// Use Multidimensional Array
string imageFilePath = processImageQue[batchLoop, 0];
string imageFileSaveLocation = processImageQue[batchLoop, 1];
BatchForm processImage = new BatchForm(imageFilePath,
imageFileSaveLocation);
processImage.Show();
}
catch
{
// Handle the error
}
}
}
When the try happens how can I make it wait for a message back from the
processImage instance of BatchForm? And how would I send back a message
from BatchForm?
thanks,
jim
Button", it then opens a new "Batch" form which processes the images files
one at a time. Unfortunatley the process takes a bit of time but my code
keeps running, not waiting for the batch to get done. How can I have the
"Main" form wait until the Batch form is finished with it's job, before the
"Main" form sends another job to the "Batch" form?
Sorry for being so wordy.. Still trying to get my mind around this problem.
For Example:
processBatchList()
{
for (batchLoop = 0; batchLoop <= numberOfRowsInDataGrid; ++batchLoop)
{
try
{
// Use Multidimensional Array
string imageFilePath = processImageQue[batchLoop, 0];
string imageFileSaveLocation = processImageQue[batchLoop, 1];
BatchForm processImage = new BatchForm(imageFilePath,
imageFileSaveLocation);
processImage.Show();
}
catch
{
// Handle the error
}
}
}
When the try happens how can I make it wait for a message back from the
processImage instance of BatchForm? And how would I send back a message
from BatchForm?
thanks,
jim