如何访问输入的Url的代码页中的Web方法 [英] How to access web methods in code page for the Url entered

查看:82
本文介绍了如何访问输入的Url的代码页中的Web方法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经添加了对该解决方案的Web引用。



现在我需要访问添加的Web引用下的Web方法..



我aspx.cs如何访问网页方法..



请任何人解释一下如何简单地访问网页方法.. 。

I have added web reference to the solution.

now i need to access the web methods present under added web reference..

I aspx.cs how to access the web methods ..

Please any one explain me how to access web methods briefly...

推荐答案

添加Web引用时,它会在项目中创建一个与Web服务具有相同或相似方法/参数的代理类。该代理类通过SOAP与您的Web服务进行通信,但隐藏了所有通信协议的内容,因此您不必担心它。



说您的Web方法是包含在namspace1.Class1中,然后你可以通过创建类Class1的对象来访问它,然后使用类的实例调用类中的方法。





祝你有愉快的一天:)
When you add a web reference it create a proxy class in your project that has the same or similar methods/arguments as your web service. That proxy class communicates with your web service via SOAP but hides all of the communications protocol stuff so you don't have to worry about it.

say your web method is contained in namspace1.Class1 then you can access it by creating an object of the class "Class1" then call the method in the class using the instance of the class.


Have a nice day:)


这篇关于如何访问输入的Url的代码页中的Web方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆