I’m trying to add ConfirmDialogHandler to dialog handler and i get NullReferenceException.
This happens on FF 3.6 with latest watin version, the same code works on IE7 and 8.
ConfirmDialogHandler confirmDialogHandler = new ConfirmDialogHandler();
browser.AddDialogHandler(confirmDialogHandler); // --> exception here
Any ideas?
Old Solution
Found the problem.
The DialogWatcher was not initialized when FF session was created added this line to watin code:
Please Note – This is the workaround
The provided solution didn’t worked
This is my workaround:
I used AutoIt dll and handled the popups by my self, code sample: