Trying to call WCF service from AJAX but method not being hit RRS feed

  • Question

  • Im following this example here with the only difference is that im uisng VS 2012 and .NET 4.5 instead of 3.5

    I downloaded the sample code and it works as expected, so its apparently something I have wrong.  I dont get any errors, but when I step into my code I can not step into my WCF method...its as if the AJAX call isnt being made because the service cant be seen?


    Loading up fiddler and hitting referesh, I dont see the request to the service url.

    Ah - ha - thats it, something is preventing the service from being called in the AJAX syntax.  The example code works ok, so something is off.  I am using a later version of the jquery extension however.    

    THIS IS NOT a WCF issue.

    • Edited by shiftbit Wednesday, July 23, 2014 12:03 AM sdfgsdfg
    Tuesday, July 22, 2014 11:49 PM


  • Hi,

    Please try to set the crossDomainScriptAccessEnabled="true" to see if it helps:

                <binding name="webHttpBindingWithJsonP" crossDomainScriptAccessEnabled="true"/>

    Then as you said that it seems that the WCF Service works well, so it will be something wrong related to the ajax call, then maybe you can try to post your thread to the ajax forum for better support.
    #Ajax Forum: .

    Thanks for your understanding.

    Best Regards,
    Amy Peng

    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Friday, July 25, 2014 10:31 AM