-1

The project I'm holding is asp.net website with static content [aspx files]

  • SOAP WSDL to the web services is provided and it's built with java and I have added a service to the project using "Add Service Reference".

I am looking for a way to consume that API with the website so as I could not understand how to call and integrate the data out of service and locate it into HTML[.aspx] page.

I have worked mostly with MVC projects but in this case I have not found any clue on how to do that.

ahmad
  • 23
  • 7

1 Answers1

0

After looking for many resources, Here is a conclusion how i solved my problem in case anyone needed that later in WebForms and C#.

1.Add Service Reference to your project using the WSDL link provided

  • now you have classes and functions identified to your project.

  • Import the namespace to your class or your webform page using corresponding syntax and after that you can instantiate object out of classes and use functions

  • using namespace.webserviceName; with class
  • <%@ Import Namespace="namespace.webserviceName" %> with webForm page.
  • One more issue popped up while I was trying to connect to the service with TLS/SSL protocols using asp.net 4.0.The Exception I received was: "The request was aborted: Could not create SSL/TLS secure channel" -To solve this refer to this question answer
ahmad
  • 23
  • 7