asmx

How to call webservice in Javascript for Firefox 3.0

孤街醉人 提交于 2019-12-31 05:51:46
问题 I have a problem with calling .Net web services with a Firefox client. A simple example will be enough for me. Server side code is like this: [WebService(Namespace = "http://tempuri.org/")] [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)] [ToolboxItem(false)] public class Service1 : System.Web.Services.WebService { [WebMethod] public string HelloWorld() { return "Hello World"; } } Client side .html code: Hello World Denemesi<br /> type="text" disabled="disabled" /></td> value=

Converting generic.list to ArrayOfInt for transmission over SOAP to web service

二次信任 提交于 2019-12-31 04:35:11
问题 I'm attempting to pass a generic list of integers from a client application to a web service using the the SOAP protocol. When I attempt to pass the list as a parameter to the web method declared in the web service, I get the error "cannot convert from generic.list to ArrayOfInt". How do I go about resolving this? // web service method [WebMethod(CacheDuration = 30, Description = "Returns the calculated sum value of all numbers supplied in the list")] public int CalculateListSum(int[] list) {

How do I secure ASP.NET web service to only allow relative path calling?

点点圈 提交于 2019-12-31 04:15:20
问题 I have ASMX services for my web application that I would only like available to the same application. Is there a way for the web service to only be accessible by the same application, such as relative/absolute path restrictions? 回答1: The easiest route would be to just not use a web service. If you're calling from the same application, you can probably just pull your logic into a separate class, and call it directly in your code, not via web service. 回答2: Two ways to do this: Have the web

.asmx Web Service Documentation

最后都变了- 提交于 2019-12-30 06:01:07
问题 I'd like my summary, param info, returns info, etc (listed below) to show up on the standard help page that .net generates for .asmx web services. /// <summary> /// Brief description /// </summary> /// <param name="fakeParamOne">Fake Param One Description</param> /// <returns>Bool representing foo</returns> The only thing that I've tried that affected the auto-generated help page in any way was this: [WebMethod(Description = "Does awesome things.")] I'm sure I'm missing something VERY simple

How to pass a DateTime value to a WebMethod (ASMX)

丶灬走出姿态 提交于 2019-12-30 04:23:53
问题 I have a WebMethod with a parameter defined as DateTime. When I call that webservice, I get this error: at System.Web.Script.Serialization.JavaScriptObjectDeserializer.DeserializePrimitiveObject() at System.Web.Script.Serialization.JavaScriptObjectDeserializer.DeserializeInternal(Int32 depth) at System.Web.Script.Serialization.JavaScriptObjectDeserializer.DeserializeDictionary(Int32 depth) at System.Web.Script.Serialization.JavaScriptObjectDeserializer.DeserializeInternal(Int32 depth) at

Application pool identity or Impersonation

…衆ロ難τιáo~ 提交于 2019-12-29 20:31:30
问题 (A question of similar vein has been asked before but both the question and the accepted answer do not provide the detail I am looking for) With the intention of running an asmx web service under a dedicated domain account what are the usage scenarios and/or pros and cons of using an Application Pool with the identity of the domain account versus Impersonation? We have 3 small internal web services that run under relatively low load and we would like to switch them to running under their own

WCF (svc) Service but client wants to connect as if it was “.asmx”

让人想犯罪 __ 提交于 2019-12-29 09:41:09
问题 I have this scenario. Client requested us to have a WebService. I created a WCF Service. After we sent them our url to the web service description, client says As it is we cannot consume a WCF service, can you publish it a web service? Now i am wondering, they are asking me for a asmx... right? Is there any way that i can "offer" my WCF service as an asmx service so i don't have to rewrite the whole thing? my first "solution" is to have an .asmx file calling my .svc files directly... i don't

How to use phonegap FileTransfer parameters with .asmx web service

不想你离开。 提交于 2019-12-29 08:29:16
问题 I am uploading an image to an asmx web service. The file upload works fine, but I am wondering how to access the parameters that I set in the javascript for the filetransfer. I want to pass the image number to the asmx SaveImage web method. Then after the file has successfully been saved I want to return the image number to the Javascript. //Javascript Calling Web Service function uploadPhoto(imageURI, imageNumber) { var options = new FileUploadOptions(), params = {}, ft = new FileTransfer(),

Adding Custom Http Headers to Web Service Proxy

ⅰ亾dé卋堺 提交于 2019-12-28 12:04:11
问题 I have an old application that uses the classic Web Service Proxy to interact with a Java Web Service. A while back the Web Service hoster decided to require a custom HTTP header to be sent with each request in order to access the service - otherwise the requests are thrown out outright (looks like this is some sort of router requirement). Regardless of what the reason I need to inject a custom HTTP header into the request. Is there any way to interact with the actual Http client to do things

What should be modified to change the URL of a web service in C#?

☆樱花仙子☆ 提交于 2019-12-28 04:27:07
问题 I have one problem and it is some time ago I have added a Webservice proxy class into my application by copying all the generated code (copy paste the text of the .cs content). And it worked! But now I need to change the URL used by this web-service proxy class and I am not sure what and where to change in the code. I would appreciate if you can give me a clue that can guide me to find the right place so that I can update the url of the web service. 回答1: You should change the URL using web