wordpress xmlrpc and microsoft access vba

I was building a database in WordPress but their table interface lacks completely and I dont want to spend 200 hours developing a backend for a once-off project.

I always used MsAccess for RAD blueprinting and I reckon you can build a better more flexible interface in 20 hours. With XHR MsAccess has some better internet capabilities these days, a nice simple XMLHttp library.

You can use it for any http rest api in the cloud.

Ajax for Access :) here’s the most basic wordpress xml-rpc call, sayHello.

Sub PutXML()

txtURL = "http://www.blog.com/xmlrpc.php"
txtUserName = "user"
txtPassword = "pwd"
  Dim objSvrHTTP As ServerXMLHTTP
  Dim strT As String
  Set objSvrHTTP = New ServerXMLHTTP
  objSvrHTTP.Open "POST", txtURL, False, CStr(txtUserName), _
  objSvrHTTP.setRequestHeader "Accept", "application/xml"
  objSvrHTTP.setRequestHeader "Content-Type", "application/xml"
  strT = ""
  strT = strT & ""
  strT = strT & "demo.sayHello"
  strT = strT & ""
  objSvrHTTP.send strT
  MsgBox objSvrHTTP.responseText

End Sub

For pre-Vista you need the MSXML 6.0 library from microsoft, in Vista I already had it installed so you can add a reference to the library and off you go.

10 thoughts on “wordpress xmlrpc and microsoft access vba”

  1. Yeah, I know. He uses PHP, afaik, but since he moved the blog I haven’t seen what he’s been doing, I keep getting blank pages :)

    1. I wouldn’t trust 5ubliminal’s coding too much.
      Try adding a comment on his website using Firefox and you’ll see what I mean!

  2. Juust, very informative site, thank dude!

    I have a question regarding your postings on xmlrpc via vba:

    I used your code from this post and from https://www.juust.org/index.php/more-vba-and-wordpress-xml-rpc/2009/10/ as the basis of a vba function to make posts to my wordpress blog from MS Office applications (using blogger_newpost), however I keep getting errors back from wp xlmrpc.


    parse error. not well formed

    I assume the error relates to the formatting of my xml params structure.
    Would you be able to do a post on a generic function to make a post from any office app to a wordpress blog.



  3. Darren Erickson

    Doesn’t seem to work for me putting it in Excel.

    All examples I’ve tried on this blog yield back “server error. invalid xml-rpc. not conforming to spec. Request must be a methodCall”, or after hours and hours of debugging on some other examples here it yields back the simple “not conforming to spec” error.

    And I’m getting really tired of seeing those two error messages and going blind trying to find just what isn’t conforming to spec in WordPress. :(

    1. Hey I was having the same problem, just spent an hour on it as well.

      Turns out capital letters are important:

      strT = “”
      strT = strT & “”
      strT = strT & “demo.sayHello”
      strT = strT & “”

      1. Okay I think it took my html literally.

        methodcall should be methodCall
        methodname should be methodName

        1. Darren Erickson

          Thanks, Tin!

          I did figure it out, probably about the same time you did. :) Finally worked out when it said request must be a methodCall, that the capital C was important, and added the captial N in name from that automatically. ;)

          XML-RPC is definitely case-sensistive in the parameters per the standard. (And is also so in WordPress’ implementation.)


          (I’m now working on getting wp.newPost and wp.editPost methods working. But I’m utterly confident I’ll get there.)

          And thank you, juust, for the examples! You’re one of the very few sources I found with actual code for actual XMLRPC and rolling it in VBA.

  4. Hey Tin, Darren, sorry for not responding, I was off to see a friend for a few days. I noticed Tin figured that one out, thanks !

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top