asmx

Methods with Nullable Types not working in ASMX Web Service using GET

℡╲_俬逩灬. 提交于 2019-12-22 05:41:35
问题 I have an ASMX Web Service set up to use the HTTP GET method. Simple methods which take basic String and Int parameters are working ok, and I can call MyService.asmx/MethodName?Param=Value and get a response back in XML. However, when I have a method which has a nullable Int (i.e. int? ), I get this error: < Method Name > Web Service method name is not valid. The error message is confusing, as the method does exist, just not in the GET scope. I presume this is because a nullable type is too

Why, when adding a service reference in VS2010, is the client class not generated?

随声附和 提交于 2019-12-22 05:37:19
问题 I'm going insane, I beleive. That is, I've never had an issue like this before, and nobody (that Google has indexed) seems to be having the same issue. Whenever I add a reference to a particular ASMX service to a VS2010 project, all of the code is generated, there is an interface ServiceSoap that represents all of the features of the service, but there is no concrete implementation of that interface anywhere in the solution! What am I doing wrong? I just right click project , add service

WCF Service instead of ASMX Web Service?

被刻印的时光 ゝ 提交于 2019-12-22 05:23:39
问题 I'm writing a SOAP Server that will act as an endpoint for an external client. The external client expects SOAP 1.1. I'll be taking embedded business objects in the SOAP messages and passing them to an internal application, getting responses back and responding with SOAP messages to the eternal client. I did the traditional ASMX based web services several years ago. Now, I've been exploring WCF Services and wondering the best approach to take. 1) Should WCF be considered a superset of ASMX

ASMX webservice not returning JSON, can only POST using application/x-www-form-urlencoded contentType

蓝咒 提交于 2019-12-22 04:34:06
问题 I can call my webservice using jQuery IF the contentType = "application/x-www-form-urlencoded; charset=utf-8" This will, however, return the xml: <string>[myjson]</string> If I try to POST to the service using "application/json; charset=utf-8" I receive a 500 error with an empty StackTrace and ExceptionType. My webservice function is never hit so I'm not quite sure how to debug this situation. My methods and classes are decorated with the appropriate attributes and are set to use JSON as

Where am I going wrong in calling ASMX web methods from jquery?

烂漫一生 提交于 2019-12-22 01:17:50
问题 I have a simple webmethod on an asp.net 2.0 application (using the 1.0 extensions not the 3.5 ajax extensions). I'm attempting to call the method from jQuery and when I do it as the countless examples show on the Internet and here on SO, I get an Internal Server Error message returned. Here's my current code: [WebMethod] [ScriptMethod(ResponseFormat=ResponseFormat.Json)] public string Select(string login) { UserProfile profile = UserProfile.GetUserProfile(login); return "{ FirstName: '" +

Namespace Prefixes in Wsdl (.net)

孤者浪人 提交于 2019-12-22 00:07:09
问题 Namespace prefixes in my wsdl are automatically generated: s1:, s2:, etc, how can i put a specific prefix for my namespaces? Can't find it anywhere... Do i have to override the xml serialization and add them by hand (how do i do that in .net webservices?) (i mean in .net2.0 asmx, the guys who are going to use this webservice say they need that specific prefix instead of s1: and there is nothing i can do about that..) Thank you very much! 回答1: Sorry I don't have time for a full example, but

Best practices - throwing exceptions from a Web Service

大憨熊 提交于 2019-12-21 20:48:01
问题 We have an ASMX web service which we invoke from our ASP.NET application using ajax (jQuery). A typical example from our web methods would be something like: [WebMethod] public void DoSomething(BusinessObject myParameter) { try { BL.DoSomethingWithParam(myParameter); } catch(Exception ex) { //logic to log the actual exception goes here //and then we throw a more user-friendly error as so: throw new Exception("Unable to perform action such an such"); } } On the client-side we would have

Assembly learning resources?

点点圈 提交于 2019-12-21 19:26:29
问题 I'm looking for a good, concise, structured way to start learning x86 ASM. I have experience with Perl, Python, and C/C++, and I've been wanting to 'get under the hood' so to speak for quite awhile now but every time I research it I find nothing but confusing, conflicting, and largely out of date information. I'm messed with MASM, FASM, HLA, and a few other things I've found just googling around, but none of them seem to offer what I'm looking for: a quick introduction with good information

ASP.NET Web Service changes port on Invoke

杀马特。学长 韩版系。学妹 提交于 2019-12-21 17:00:05
问题 I have a ASP.NET Web Service on IIS, that is working on port 8080. On port 80 I have Apache, that is redirecting some web sites to IIS. On this case, I can access the Web Service page (http://example.com/service/), which gives me all the methods available. However, when I try to invoke a method, it goes to a web page like this one: http://example.com:8080/service/Service1.asmx/Method. Of course that a public access can not see any result, the port 8080 is blocked and can not be opened.

Should I be using Web API vs Web Methods?

大城市里の小女人 提交于 2019-12-21 09:15:22
问题 I'm trying to understand web api and some news about web methods. I've heard that we should stop using web methods from a few sources. Additionally, is Web API the successor if web methods should no longer be used? 回答1: Web methods are part of the ASMX technology. ASMX is a legacy technology, and should not be used for new development. WCF or ASP.NET Web API should be used for all new development of web service clients and servers. One hint: Microsoft has retired the ASMX Forum on MSDN.