Other Languages - webserver - json - vba

Asked By tina silca
10-Feb-12 09:03 AM
Hi,

I don't have so much experience on this and I'm facing an issue.
I've a webserver that contains a function getProject.
This function receives 3 parameters and retrieves a text as result.

how can I call the webserver and pass the 3 parameters?

thanks in advance

Private Function auth(url As String, ByRef usernme As String, ByRef passord As String, ByRef projctid As String)
   ' Dim objSClient As MSSOAPLib30.SoapClient30    ' Remove the 30 if using an earlier version of SOAP
    Dim fResult As Single
Dim objClient As SoapClient30
Dim objConn As SoapConnector30
Set objConn = New HttpConnector30
    ' Point the SOAP API to the web service that we want to call...
    Set objClient = New SoapClient30
    Set ws = CreateObject("MSOSOAP.SoapClient30")
    objConn.Property("EndPointURL") = url
   objConn.Property("SoapAction") = "getProject"
    objConn.BeginMessage
    Set objSerial = New SoapSerializer30
     objSerial.Init objConn.InputStream
    'Call objClient.MSSoapInit(par_WSDLFile:=url,
ws.MSSoapInit url
    ' Call the web service
    fResult = ws.getProject
    
    Set objSClient = Nothing

    ss = fResult
    
End Function

  kalpana aparnathi replied to tina silca
10-Feb-12 01:21 PM
hi,

Try this  example code for JSON:

$.ajax({  
    type
: "POST",  
    url
: url,  
    data
:

"{'Id1':'2','Id2':'2'}",

 
    contentType
: "application/json; charset=utf-8",
    dataType
: "json",
    success
: callback
});

  tina silca replied to kalpana aparnathi
13-Feb-12 05:31 AM
Hi,
Thanks but I need to call the webserver from VBA code.
I'm using MS Project 2007

best regards
Create New Account
help
microsoft project Project what is the purpose of Microsoft Project Project Discussions Microsoft Project (1) VBA (1) Juan (1) CFAF865342AD (1) Start here: http: / / office.microsoft.com / en-us
How do we determine crew size with Microsoft Project? Project How do we determine crew size with Microsoft Project? Project Discussions Microsoft Project (1) Excel (1) VBA (1) Microsoft Project Crews (1) Database (1) Project Project (1) Physical
How do i "strikethrough" when using Microsoft Project Project How do i strike through a sentence (as you will do in a Microsoft Word Font) when using Microsoft Project? Project Discussions Microsoft Project (1) Microsoft Word (1) Project 2010 (1) VBA (1) Database (1) Strikethrough (1) Thunk
Project - VBA Project window - Excel 2003 Excel Hi, 1. I open a file, write some code, then close file 2. even though the file was closed it is code is still viewable in Project - VBA Project window, as if the file was still open the only way I know to have the file REALLY closed in Project - VBA Project window is to Exit and re-start Excel does anyone know a better way
Interfacing AJERA with Microsoft Project or Microsoft Project Serv Project I am curious if anyone has any experience interfacing AJERA database data with Microsoft Project or Microsoft Project Server 2007. I would like to develop a product that allows me to create