Is it possible to load an URL into WebBrowser object without form (Ex: Windows service) save to the disk as file. I know how to do the above scenario by placing control over the form, loading URL then saving to a disk. But I don't know how can load the (page) given URL into WebBrowser object without forms. I tried to use and declare the object then tried to Navigate. I got error at the point of Navigate method (I guess, because there is nothing to navigate). Any ideas? Thanks, Vijay
Vijay, are you trying to build a webpage downloader? if yes; you probably need to consider other option than using WebBrowser object (it's an over-kill, why browse when there you are not intersted to look at what is being browsed?) for instance System.Net offer some file downloading thru http... hope this helps -- --Dr. Abdel "Vijay" wrote: > Is it possible to load an URL into WebBrowser object without form (Ex: > Windows service) save to the disk as file. > > I know how to do the above scenario by placing control over the form, > loading URL then saving to a disk. But I don't know how can load the (page) > given URL into WebBrowser object without forms. I tried to use and declare > the object then tried to Navigate. I got error at the point of Navigate > method (I guess, because there is nothing to navigate). > > Any ideas? > > Thanks, > Vijay >
The internal (to the company) URL that I am trying to load and save to disk takes autogenerated (I need to call a webservice to get session ID) session ID as parameter. This whole URL with session ID works fine with WebBrowser control but not with WebClient. If I use WebClient, the retrieved page displays a message something like "session got expired". Any inputs? Thanks, Vijay "Dr. Abdel." wrote: > Vijay, > > are you trying to build a webpage downloader? > if yes; you probably need to consider other option than using WebBrowser > object (it's an over-kill, why browse when there you are not intersted to > look at what is being browsed?) for instance System.Net offer some file > downloading thru http... > > hope this helps > -- > --Dr. Abdel > > > "Vijay" wrote: > > > Is it possible to load an URL into WebBrowser object without form (Ex: > > Windows service) save to the disk as file. > > > > I know how to do the above scenario by placing control over the form, > > loading URL then saving to a disk. But I don't know how can load the (page) > > given URL into WebBrowser object without forms. I tried to use and declare > > the object then tried to Navigate. I got error at the point of Navigate > > method (I guess, because there is nothing to navigate). > > > > Any ideas? > > > > Thanks, > > Vijay > >