views:

111

answers:

1

Hi, I am trying to retrieve data from a page wich first requires to log on, I am using a webControl on a c# winform, and when I try to log on an error pops up telling me "Object doesn't support this property or method" in a .js file at cerain line, the method being called is

window.external.AutoCompleteSaveForm 

which I have no Idea what it does. the webBrowser.ObjectForScripting is set to this

I think the problem is the ObjectForScripting, but I don't really know which Object supports this method.

thanks in advance.

+1  A: 

You are right, you must provide an object for ObjectForScripting. It could be anything, as long as it has the [ComVisible(true)] attribute so it is callable from COM code. To keep the script happy, you must provide a public AutoCompleteSaveForm(object) method. No need to do anything. The MSDN library article has a decent example.

Hans Passant
THKX works perfectly now.
Luiscencio