Hi,
I'm gonna create a BackgroundWorker with an anonymous method.
I've written the following code :

PHP Code:
BackgroundWorker bgw = new BackgroundWorker();
bgw.DoWork += new DoWorkEventHandler(
    () =>
    {
        
int i 0;
        foreach (var 
item in query2)
        {
            ....
            ....
        }
    }
); 
But Delegate 'System.ComponentModel.DoWorkEventHandler' does not take '0' arguments and I have to pass two objects to the anonymous method : object sender, DoWorkEventArgs e

Could you please guide me, how I can do it ?
Thanks.