[AccessD] Calling API's from VBA

newsgrps at dalyn.co.nz newsgrps at dalyn.co.nz
Sun Aug 9 23:22:15 CDT 2020


Thanks Stuart, I missed that one.

-----Original Message-----
From: AccessD <accessd-bounces at databaseadvisors.com> On Behalf Of Stuart
McLachlan
Sent: Monday, 10 August 2020 4:14 pm
To: Access Developers discussion and problem solving
<accessd at databaseadvisors.com>
Subject: Re: [AccessD] Calling API's from VBA

There are several ways to do it.

Gustav posted a method of getting  data a few days ago using XMLHTTP

   https://github.com/GustavBrock/VBA.Random

The actual module code is at

https://github.com/GustavBrock/VBA.Random/blob/master/Random.bas

The relevant part of that code for your purposes is the function:

 Private Function RetrieveDataResponse( _
    ByVal ServiceUrl As String, _
    ByRef ResponseText As String) _
    As Boolean

A variation of that using
XmlHttp.Open "PUT", ServiceUrl, Async
instead of
XmlHttp.Open "GET", ServiceUrl, Async
should work the other way.



On 10 Aug 2020 at 15:04, newsgrps at dalyn.co.nz wrote:

> Hi Listers,
> 
> I have a client that wants to be able to call a web api to push data and
then call another one to pull data back again.
> 
> Does anyone know of resources that can give me guidance as how to do this
in Access?
> 
> Regards
> 
> David Emerson
> Dalyn Software Ltd
> Wellington, New Zealand



More information about the AccessD mailing list