Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP passing credential to WCF services [modified]

ASP passing credential to WCF services [modified]

Scheduled Pinned Locked Moved Web Development
questioncsharpwcfcomxml
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    amit k mistry
    wrote on last edited by
    #1

    Hi, I have an asp page that I want to connect with WCF Service Can someone guide me how can I connect and call the service? <% Dim soapServer soapServer = "https://XXXXXX.YYYYYY.com/ZZZZZZZZ/20100201/ABC.svc" Set xmlhttp = CreateObject("MSXML2.ServerXMLHTTP") xmlhttp.open "POST", soapServer, False,"USERNAME","PASSWORD" xmlhttp.setRequestHeader "SOAPAction", POST & " " & soapServer & " HTTP/1.1" xmlhttp.setRequestHeader "Content-Type", "text/xml; charset=utf-8" Response.Write "About to call WCF Web Service from Classic ASP..." xmlhttp.send() Response.Write "<br>Finished calling Web Service." Response.Write "<br>Status = " & "<font color='red'>" & xmlhttp.statusText & "</font>" Response.Write "<br>ResponseText = " & xmlhttp.responseText %> I got Status = Bad Request Result when I ran the asp page . I don't have idea whether my creadetial get pass or fail or do I properly connect with WCF service or not ? Can any one help me in this matter?

    modified on Monday, April 26, 2010 3:20 PM

    R 1 Reply Last reply
    0
    • A amit k mistry

      Hi, I have an asp page that I want to connect with WCF Service Can someone guide me how can I connect and call the service? <% Dim soapServer soapServer = "https://XXXXXX.YYYYYY.com/ZZZZZZZZ/20100201/ABC.svc" Set xmlhttp = CreateObject("MSXML2.ServerXMLHTTP") xmlhttp.open "POST", soapServer, False,"USERNAME","PASSWORD" xmlhttp.setRequestHeader "SOAPAction", POST & " " & soapServer & " HTTP/1.1" xmlhttp.setRequestHeader "Content-Type", "text/xml; charset=utf-8" Response.Write "About to call WCF Web Service from Classic ASP..." xmlhttp.send() Response.Write "<br>Finished calling Web Service." Response.Write "<br>Status = " & "<font color='red'>" & xmlhttp.statusText & "</font>" Response.Write "<br>ResponseText = " & xmlhttp.responseText %> I got Status = Bad Request Result when I ran the asp page . I don't have idea whether my creadetial get pass or fail or do I properly connect with WCF service or not ? Can any one help me in this matter?

      modified on Monday, April 26, 2010 3:20 PM

      R Offline
      R Offline
      Ravi Bhavnani
      wrote on last edited by
      #2

      It seems you want to pass the client's network credentials in your call to the service. See this[^] article. /ravi

      My new year resolution: 2048 x 1536 Home | Articles | My .NET bits | Freeware ravib(at)ravib(dot)com

      A 1 Reply Last reply
      0
      • R Ravi Bhavnani

        It seems you want to pass the client's network credentials in your call to the service. See this[^] article. /ravi

        My new year resolution: 2048 x 1536 Home | Articles | My .NET bits | Freeware ravib(at)ravib(dot)com

        A Offline
        A Offline
        amit k mistry
        wrote on last edited by
        #3

        I have found 2 more sample code for basicHTTP binding http://www.sourcecodesworld.com/source/show.asp?ScriptID=249[^] but. still my answer is peding... how can I get the proper response status whether i am connected or not ???

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups