Hey,
I am creating BGwrks dynamically and assigning functions... i have a class worker and i created two functions with two parameters as i have to pass arguments...
Inside class i wrote function to accept parameters like this.
Now i created a BG and using these code i tried to assign functions
Now strangely i got this error.. i know i did some silly mistake but i cant figure it out..
i never faced this problem previously.. any light on this will be great.. :)
EDIT: I deleted everything in obj, debug folder and rebuilt. Removed reference and added again.. now it works!! :( was very strange!!
I am creating BGwrks dynamically and assigning functions... i have a class worker and i created two functions with two parameters as i have to pass arguments...
Inside class i wrote function to accept parameters like this.
Code:
Public Function Worker_Dowork(ByRef sender As Object, ByRef e As System.ComponentModel.DoWorkEventArgs)'.
Code:
Dim Bg as new BackgroundWorker
Addhandler Bg.DoWork, AddressOf Obj.Worker_DoWork
Bg.runWorkerAsync({Param1,Param2})
Code:
Argument not specified for parameter 'e' of 'Public Function Worker_Dowork(ByRef sender As Object, ByRef e As System.ComponentModel.DoWorkEventArgs) As Object'.
EDIT: I deleted everything in obj, debug folder and rebuilt. Removed reference and added again.. now it works!! :( was very strange!!