public bool ProcessBOFilesForRetailer(int retailerId) { if (retailerId <= 0) { return(false); } Trace.WriteLine("Processing for " + retailerId); Task task = new TaskFactory(TaskCreationOptions.LongRunning, TaskContinuationOptions.LongRunning) .StartNew(() => { JobsProcessor.ProcessJobs(retailerId); }); return(true); }
protected void Process_Click(object sender, EventArgs e) { int retailerId = int.Parse(txtID.Text); JobsProcessor.ProcessJobs(retailerId); }