Connecting Tech Pros Worldwide Help | Site Map

How to query a website from a form

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 12th, 2005, 04:22 PM
Wim Verhavert
Guest
 
Posts: n/a
Default How to query a website from a form

Hi all,

For gathering certain information in building my database, I'm depending
on the things I found on the web, especially one website (let's call it
www.mywebsite.com). Is there a way to query this site (it has fill in
boxes on the page and a search button) depending on values in my form
and getting the results back in my form? This (general) question is
keeping me out of my sleep for weeks now....

Any tip is appreciated....

Kind regards,

Wim


  #2  
Old November 12th, 2005, 04:23 PM
TC
Guest
 
Posts: n/a
Default Re: How to query a website from a form

Try the microsoft webbrowser control. Drop one onto your form, then you can
use the .Navigate method to go to that website. Then you can use the methods
& properties of the HTML Document Object Model (which are exposed through
the webbrowser control) to retrieve data from the HTML that the website sent
you.

HTH,
TC


"Wim Verhavert" <wim_verhavert@yahoo.com> wrote in message
news:1070560814.112262@seven.kulnet.kuleuven.ac.be ...[color=blue]
> Hi all,
>
> For gathering certain information in building my database, I'm depending
> on the things I found on the web, especially one website (let's call it
> www.mywebsite.com). Is there a way to query this site (it has fill in
> boxes on the page and a search button) depending on values in my form
> and getting the results back in my form? This (general) question is
> keeping me out of my sleep for weeks now....
>
> Any tip is appreciated....
>
> Kind regards,
>
> Wim
>[/color]


  #3  
Old November 12th, 2005, 04:23 PM
Wim Verhavert
Guest
 
Posts: n/a
Default Re: How to query a website from a form

Is there also a way of automatically filling in the form on that
website? That the program doesn't automatically outputs the data to my
form is not so big a problem.

Thanks anyway!

Regards,
WV

TC wrote:[color=blue]
> Try the microsoft webbrowser control. Drop one onto your form, then you can
> use the .Navigate method to go to that website. Then you can use the methods
> & properties of the HTML Document Object Model (which are exposed through
> the webbrowser control) to retrieve data from the HTML that the website sent
> you.
>
> HTH,
> TC
>
>
> "Wim Verhavert" <wim_verhavert@yahoo.com> wrote in message
> news:1070560814.112262@seven.kulnet.kuleuven.ac.be ...
>[color=green]
>>Hi all,
>>
>>For gathering certain information in building my database, I'm depending
>>on the things I found on the web, especially one website (let's call it
>>www.mywebsite.com). Is there a way to query this site (it has fill in
>>boxes on the page and a search button) depending on values in my form
>>and getting the results back in my form? This (general) question is
>>keeping me out of my sleep for weeks now....
>>
>>Any tip is appreciated....
>>
>>Kind regards,
>>
>>Wim
>>[/color]
>
>
>[/color]

  #4  
Old November 12th, 2005, 04:25 PM
TC
Guest
 
Posts: n/a
Default Re: How to query a website from a form

Yes, you just use the objects, methods & properties of the Document Object
Model, which is exposed by the webbrowser control. This is similar in
principle (but different in detail) to programming in VBA. For example,
you'd use the Submit method of the relevant named form of the Document
object, to send the form.

Wim, I haven't done this for some time, & the details are no longer clear in
my mind. So you'll have to do some research! Check out the web for
information on "webbrowser control" and "HTML Document Object Model".

HTH,
TC


"Wim Verhavert" <wim_verhavert@yahoo.com> wrote in message
news:1070615295.353038@seven.kulnet.kuleuven.ac.be ...[color=blue]
> Is there also a way of automatically filling in the form on that
> website? That the program doesn't automatically outputs the data to my
> form is not so big a problem.
>
> Thanks anyway!
>
> Regards,
> WV
>
> TC wrote:[color=green]
> > Try the microsoft webbrowser control. Drop one onto your form, then you[/color][/color]
can[color=blue][color=green]
> > use the .Navigate method to go to that website. Then you can use the[/color][/color]
methods[color=blue][color=green]
> > & properties of the HTML Document Object Model (which are exposed[/color][/color]
through[color=blue][color=green]
> > the webbrowser control) to retrieve data from the HTML that the website[/color][/color]
sent[color=blue][color=green]
> > you.
> >
> > HTH,
> > TC
> >
> >
> > "Wim Verhavert" <wim_verhavert@yahoo.com> wrote in message
> > news:1070560814.112262@seven.kulnet.kuleuven.ac.be ...
> >[color=darkred]
> >>Hi all,
> >>
> >>For gathering certain information in building my database, I'm depending
> >>on the things I found on the web, especially one website (let's call it
> >>www.mywebsite.com). Is there a way to query this site (it has fill in
> >>boxes on the page and a search button) depending on values in my form
> >>and getting the results back in my form? This (general) question is
> >>keeping me out of my sleep for weeks now....
> >>
> >>Any tip is appreciated....
> >>
> >>Kind regards,
> >>
> >>Wim
> >>[/color]
> >
> >
> >[/color]
>[/color]


  #5  
Old November 12th, 2005, 04:31 PM
Wim Verhavert
Guest
 
Posts: n/a
Default Re: How to query a website from a form

Thanks a lot for all the help!!! You put me in a good thinking path...

TC wrote:
[color=blue]
> Yes, you just use the objects, methods & properties of the Document Object
> Model, which is exposed by the webbrowser control. This is similar in
> principle (but different in detail) to programming in VBA. For example,
> you'd use the Submit method of the relevant named form of the Document
> object, to send the form.
>
> Wim, I haven't done this for some time, & the details are no longer clear in
> my mind. So you'll have to do some research! Check out the web for
> information on "webbrowser control" and "HTML Document Object Model".
>
> HTH,
> TC
>
>
> "Wim Verhavert" <wim_verhavert@yahoo.com> wrote in message
> news:1070615295.353038@seven.kulnet.kuleuven.ac.be ...
>[color=green]
>>Is there also a way of automatically filling in the form on that
>>website? That the program doesn't automatically outputs the data to my
>>form is not so big a problem.
>>
>>Thanks anyway!
>>
>>Regards,
>>WV
>>
>>TC wrote:
>>[color=darkred]
>>>Try the microsoft webbrowser control. Drop one onto your form, then you[/color][/color]
>
> can
>[color=green][color=darkred]
>>>use the .Navigate method to go to that website. Then you can use the[/color][/color]
>
> methods
>[color=green][color=darkred]
>>>& properties of the HTML Document Object Model (which are exposed[/color][/color]
>
> through
>[color=green][color=darkred]
>>>the webbrowser control) to retrieve data from the HTML that the website[/color][/color]
>
> sent
>[color=green][color=darkred]
>>>you.
>>>
>>>HTH,
>>>TC
>>>
>>>
>>>"Wim Verhavert" <wim_verhavert@yahoo.com> wrote in message
>>>news:1070560814.112262@seven.kulnet.kuleuven.ac .be...
>>>
>>>
>>>>Hi all,
>>>>
>>>>For gathering certain information in building my database, I'm depending
>>>>on the things I found on the web, especially one website (let's call it
>>>>www.mywebsite.com). Is there a way to query this site (it has fill in
>>>>boxes on the page and a search button) depending on values in my form
>>>>and getting the results back in my form? This (general) question is
>>>>keeping me out of my sleep for weeks now....
>>>>
>>>>Any tip is appreciated....
>>>>
>>>>Kind regards,
>>>>
>>>>Wim
>>>>
>>>
>>>
>>>[/color][/color]
>
>[/color]

 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,840 network members.