Need help with using HTTP from VBA in Access 2003.

  • Thread starter Thread starter Janet Wilson
  • Start date Start date
J

Janet Wilson

Can someone point me to some good instructions on using the
WinInet.dll functions from VBA?

I need to interact with a MySQL database via HTTP strings.
We already have the database set up and a PHP script that can receive
commands via HTTP. The script receives the HTTP commands and performs
the database actions, then responds with XML.

This system already works when I test it from IE. I simply send it an
HTTP string similar to this:

http://www.lmc.bz/tblAdvisories.php...CT * FROM tblAdvisories WHERE contact_id = 12

The PHP script executes the query and sends back the results in XML. I
just need to know how to set up the VBA code to send the requests. I
THINK I must use WinInet functions to do this. Am I correct, or is
there a simpler way to do it, perhaps using ADO?

More info is available if needed.

Thanks,

JW
 
Hello, Lauren Wilson.

Please don't multipost the same question in three different newsgroups,
especially under different names, as the experts who answer questions are
likely to get angry when they find out you wasted their time because your
question has already been answered in another newsgroup. Please see the
following Web page:

http://www.mvps.org/access/netiquette.htm

Last time you were posting a similar question as Cheryl Langdon, who was
supposedly being helped out of a desperate family crisis, the application
was for a charity to tutor disadvantaged youth, yada, yada, yada. So who is
Janet supposed to be? A cousin from Georgia on her way to Hollywood to get
a job in the movies but needs gas money to get there, so she's working on
your software application for you to pay you back the money you've loaned
her?

You're passing the User ID and password as parameters in the URL to a
script? Do you realize what a security risk this is?
Am I correct, or is
there a simpler way to do it, perhaps using ADO?

Have you considered the Web Browser Active-X control?

HTH.
Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips and tutorials.
http://www.Access.QBuilt.com/html/expert_contributors2.html for contact
info.
 
Hello, Lauren Wilson.

Who is this? I don't know what you are talking about. If you don't
want to respond, then don't. Looks like you have a lot of time on
your hands.
 

After reviewing this page, I recall seeing it a couple of years ago. I
did not pay too much attention to it due to this excerpt:

"The HTTP object provides download only capabilities and can be used
to download a file from any HTTP server, provided that you know the
correct URL."

My needs require that I be able to send an SQL query to the URL. I
KNOW it can be done because I have an MDE app from another
organization that does it.

Any ideas on that?

Thank you Arvin.
 
Hello, Lauren Wilson.
Who is this? I don't know what you are talking about.

Yes. You do. Each computer leaves a footprint when it connects to the
Internet, and you're using the same computer to post this question as you
used to post these other questions on the same topic of using VBA and ADO to
access a database on the Web via HTTP, but you used various identities:

Charles Wilson:

http://groups.google.com/group/comp...b127/1e1337d052d2b604?&hl=en#1e1337d052d2b604

Charles Wilson:

http://groups.google.com/group/micr...2a79/29572e4c190c9f49?&hl=en#29572e4c190c9f49

Cheryl Langdon:

http://groups.google.com/group/comp...bd93/570034ec41e98c0a?&hl=en#570034ec41e98c0a

Lauren Wilson:

http://groups.google.com/group/comp...c082/39b3d13e1e96fa7d?&hl=en#39b3d13e1e96fa7d

Lauren Wilson:

http://groups.google.com/group/comp...ca91/e8dd3e8a4689309e?&hl=en#e8dd3e8a4689309e

Lauren Wilson:

http://groups.google.com/group/comp...83fb/cbf28a78f1faab64?&hl=en#cbf28a78f1faab64
If you don't
want to respond, then don't.

If I didn't want to respond, then I wouldn't have taken the time to answer
your questions and given you good advice, and also remind you not to
multipost, so that you get kill filed by any experts for making this
mistake -- so that you'll have future opportunities to get your questions
answered by the largest number of experts available.
Looks like you have a lot of time on
your hands.

I have the same amount of time on my hands as you do. It may appear that I
have more time to do things than you do because I can get the job done
quicker, so I still have time left over to answer Access users' questions on
how to fix their Access problems. I have a busy schedule, so it's hard to
make time to help others with their computer problems on a regular basis,
but I wouldn't do it if I didn't enjoy it. As is the same with the other
experts who take the time to answer questions in the newsgroups. Our time
is precious, so please don't waste it by playing games and multiposting the
same question under different identities and subject lines. When you don't
intentionally spread your question out to the four winds, the experts can
concentrate their efforts on your problem in a single thread, and possibly
research the history of your problem by Googling on your name, in order to
give you the best advice based upon your unique circumstances, without you
having to repeat yourself every time you want to become "someone new."

HTH.
Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips and tutorials.
http://www.Access.QBuilt.com/html/expert_contributors2.html for contact
info.
 
Hello, Lauren Wilson.

Perhaps I should have listed the other multiposts of this same question,
under multiple identities and under multiple subject lines, in addition to
the two listed under Charles Wilson in my previous post. I'm mentioning
this because five multiposts under multiple identities is excessive, and by
using different names you obviously went out of your way to accomplish it.
It's not a good way to make people happy to answer your future questions
when they find out the question they've spent time answering has already
been answered several times by others.

Janet Wilson:

http://groups.google.com/group/micr...e7dcc943c3890046?tvc=1&hl=en#e7dcc943c3890046

Charles Wilson:

http://groups.google.com/group/micr...8536/365b47dd383e27a5?&hl=en#365b47dd383e27a5

HTH.
Gunny
 
Back
Top