You need to sign in to do that
Don't have an account?
Login to SFDC object in ASP does not work on server
Not sure why, but the vbscript I wrote in an .asp page (not asp.NET) runs fine on my local PC webserver but gives me an error message when I try to run it from the server where it will eventually reside. I installed the "Connect for Office" software on the server. Here's the simple code I'm trying to run just to establish a connection:
<%@ language=VBScript %>
<% dim sfdc
Set sfdc = server.createobject("SForceOfficeToolkit3.SForceSession3")
If not sfdc.login("username", "password") Then
Response.write "Login error: " & sfdc.ErrorMessage
End If
On my local PC, it runs fine - no error messages. On the server, I get this message back from the sfdc object:
Login error: Unable to send request to server. Access is denied
Any thoughts? I thought maybe the security token might be necessary as I'm using a specific user account to log into SF, but I was able to actually log into the Salesforce SFA using that account without needing a token, so I assume the IP address is trusted. By the way, I can run this code (with a little modification of change the response.write to "msgbox") in an EXCEL macro ON THIS SERVER and not get any errors. It seems to not like it only when running from this vbscript in my ASP page.