WCF / ASMX :: Android Could Not Access REST Service?

Oct 26, 2010

[Code]....

this method i can access using asp.net but not by using a android.. i have checked for the headers etc.. the response is OK in android while debugging but the data is not inserted..

what is the equivalent of stringbuilder in android??

in android i use

StringEntity se = new StringEntity(json.toString());

//and post the data to my service...

post.setEntity(se);

what is the equivalent of stringentity in C# and what can i do for this prob?

View 2 Replies


Similar Messages:

Consuming A WCF REST Service From Android Is Very Slow?

Aug 31, 2010

I have a WCF REST service built with C# and it returns an image as part of a CPU intensive operation. The client is running on Android (Java) By default, it will return a text JSON object that looks something like this:

{"d",[9,0,77,12,11,...]}

Those are they bytes of the image. Fine. However, all the solutions for decoding this JSON are intolerably slow. I've tried Gson, Jackson, and the built-in Android JSONObject class. I have no idea why they are so slow.

As an alternative solution, I have my REST service return a GUID, and then that GUID can be used by the Android client to go to a regular URL that serves up the image as a regular binary stream, via an MVC controller.

This works well, and it fast, and is pretty easy to handle on the Android side. However, it does feel like a bit of kludge and kind of a violation of the REST design principles. Am I missing something here? Is there a better way to do this?

View 4 Replies

WCF / ASMX :: Can Pass Object In Rest Service Uri

Jan 18, 2011

can Pass object in Rest Service Uri

View 1 Replies

WCF / ASMX :: How To Display Only Part Of A Page Using The REST Web Service

Oct 1, 2010

My code below

BtnClick
YahooSample();
public void YahooSample()
{
HttpWebRequest request = WebRequest.Create("http://developer.yahoo.com/yui/") as HttpWebRequest;

[Code]....

View 1 Replies

WCF / ASMX :: Post Arbitrary Data To An REST WCF Service?

Mar 30, 2010

How may I post arbitrary data to a REST WCF webservice? I mean, wihout use contracts.

Because my data is dynamic and I cannot have contracts, I want to get ride of the serialization overhead.

How should I declare my service and method?

View 1 Replies

Architecture :: Create REST Based Web Service Using Asmx?

Apr 12, 2010

Is it possible to create REST based web service using asmx?

View 1 Replies

Talking To A Rest Service / Call A Rest Service Without Having To Redirect?

Feb 8, 2010

I need to call a Rest service but would like to do so without having to redirect. Here is my dilemma. The Rest service we are trying to integrate offers the option to sign up for a subscription but does not allow us to upgrade an existing subscription. So if a user wants to upgrade an existing subscription we have to first cancel and then have the user sign up for a brand new subscription. I don't know how I can make this so it flows nicely in my code. I ideally I would like to do something like this

User decides to upgrade

Click upgrade button

Existing account is being cancelled, if cancellation was successful

New account is being created

How can I do this with a Rest service? Here is a sample URI/URL

https://someservice.com?
Action=CancelSubscriptionAndRefund
&AWSAccessKeyId=AKIAIIFXJCFIHITREP4Q
&CallerReference=CallerReference07
&CancelReason=MyWish
&RefundAmount.CurrencyCode=USD
&RefundAmount.Value=1
&SignatureMethod=HmacSHA256
&SignatureVersion=2
&Signature=1uFUSSFvau1zadnSzKRS5ZchuLMn9p5M3ifaHGHie7M%3D
&SubscriptionId=17d62772-c53e-4bdb-9667-65d7b7841cfc
&Timestamp=2009-10-06T08%3A05%3A13.296Z
&Version=2008-09-

Could anybody give me some ideas how to make this work in an elegant manner. We thought we could keep the old subscription and then just sign the user up for a new subscription for the difference of the money. For example the first subscription would be 2.95 and the second one would be 2.00 which would amount to a subscription of 4.95. I think it is not elegant and the user would see 2 charges on the credit card, weird, I think. Since I don't know much about Rest maybe there is a way that this can be solved.

View 1 Replies

C# - What Is The Difference Between Rest Web Service And Rest Enabled Wcf Service

Oct 15, 2010

I have developed an rest enable wcf service by using the following link

[URL]

Now I want to know is there any difference between rest enabled wcf service (or restful web service) & rest web service ? If there is any difference then what is that ? If there is difference the can you provide me any link (which represents steps visually as in above link) through which I can develop rest web service ?

View 2 Replies

WCF / ASMX :: How To Access Web Service In WCF Service

May 24, 2010

I want to access simple web service inside WCF service. How can i achieve it?

View 2 Replies

WCF / ASMX :: Can't Access Service.svc.cs

Jun 9, 2010

Im using VS 2008, 3.5 framework I want to use wcf, but javascript cant access to myservice.svc error : Message: 'MapService' is undefined;

calling mapservice ;
function getselectedIl() {
var firstLetter =
"caglar";
var proxy =
new MapService();
proxy.GetSuggestions(firstLetter);
defining mapservice;
<asp:ScriptManager ID="ScriptManager2" runat="server">
<Services>
<asp:ServiceReference Path="MapService.svc" />
</Services>
</asp:ScriptManager>
mapservice.svc.cs;
[ServiceContract(Namespace = "")]
[AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]
public class MapService
{
[OperationContract]
public string GetSuggestions(string firstLetter)
{
return "basarili";
}
}

View 6 Replies

WCF / ASMX :: Access And Web Service?

Jun 29, 2010

I'm getting a strange data download from an Access database.Using Visual Web Developer 2010 Express, I created a web service that places records from an Access database in server cache and then reads the records, one at a time, from the cache. The data in the records is converted to a delimited string. The web service is called from an e-learning program called Toolbook that places Http Post calls to the web service. The web services uses vb and .Net Framework 2.0.

All works correctly with one exception. When a record in the Access db contains "&", it is downloaded to the Toolbook e-learning program as "&". If I place && in the record, I get "&&".If I download the data from the Access db using a classic.asp file rather than the web service, the "&" displays correctly.

View 2 Replies

WCF / ASMX :: Trying To Access A Self Hosted Wcf Service?

Oct 3, 2010

I get this error when trying to access a self hosted wcf service...

[Code]....

Can someone explain what I need to do to get this to work, I do not have any cross domain policy file. And don't know how that is supposed to look like.

View 1 Replies

WCF / ASMX :: Web Service Access From Javascript?

Sep 8, 2010

am new to webservice accessing from javascript.I call a webmethod from javascript which returns a string array. whith this array i bind a dropdown list at client.At dropdownList selectedIndexchanged event I found there is no item in DropDownList. Is there any way how to bind the DropDownList using webMethod so that on postback i can get the dropdowns item.

View 3 Replies

WCF / ASMX :: Unable To Access Web Service From Excel VBA

Feb 4, 2011

I have a web service which is accessible from the browser. When I try to access the same web service which is hosted on Windows Server 2008 R2, from an excel Macro, it says

Run-time error '-2147220991' (80040201)':

Server was unable to process request --> The request failed with HTTP status 404: Not Found.

The excel macro works fine when I try to access the same web service on the other server(Windows 2000 Server)

The web service is developed using .Net 2.0.

I'm posting the URL for the web service for your reference.

URLs which are not being accessible from Excel.

[URL]

[URL]

URLs which are being accessible from Excel.

[URL]

[URL]

Both Web services and Excel macros are old applications which have been running fine for years. The only change is that the application is being migrated to a new server(MCDEAGDWEB202) which has Windows Server 2008 R2 and SQL Server 2008.

The Old server(MCDEAGLWEB005B) has Windows Server 2000 and SQL Server 2000.

View 4 Replies

WCF / ASMX :: Unable To Access The Functions From The Web Service

May 28, 2010

I have added a web service as a reference to a windows application using "AddWebRefrence" option. And I am unable to access the funtions in the web service but instead i get the functionnames followed by the completedeventargs and completedeventhandler.

What am I doing wrong and how can i access the funtions in the web service.

View 3 Replies

WCF / ASMX :: Can Access Two Applications With Web Service At The Same Time

Aug 4, 2010

have two different applications. The only access between those two applications is Web Service.I want to delete records in the another application database by passing primary key of that table.I don't have access to database where I have to delete the records.For this, where I have to write the delete functionality.? In web service or or in my application.

View 14 Replies

WCF / ASMX :: Access Web Service Webmethod In Javascript?

Apr 29, 2010

How to Access Webservice Webmethod in Javascript

View 4 Replies

WCF / ASMX :: Access Session Variables Through A Web Service?

Mar 29, 2011

In my ASP.net website we are going to use Silverlight to display some interactive diagrams. The users can add, edit and delete various diagrams on the silverlight front end. Silverlight will call Web Service methods to save the changes into the database. Besides the data being passed by silverlight to web service call, we also need to pass some data from the session (like logged on user id etc.) to the web service call.

My question is that how silverlight can access session data? I am trying to pass session information via a webservice method call over to Silverlight but, the session variables inside the web service methods are returning null value.

The Web Service is running under the same web root where the ASP.net website using Silverlight is also hosted. I have made EnableSession = True for web properties.

View 1 Replies

WCF / ASMX :: Web Page Access Delphi Web Service?

Dec 14, 2010

I have created a dynamic web page . It gets loaded using a file keys.txt. This file holds the keys which are used to display a web page like panels order, text of labels , number of buttons and so on..It is consuming a web service written in delphi. All works fine but when 2 users try to access this service simultaneously then a error is displayed (Internal Server Error 500) "Access violation at address 0040404C in module "accelerate_gateway.dll". Read of address 00000000"Accelerate gateway is the name of delphi web service.It seems to me the problem of multi threading in delphi service ??But I have not done any multi threading in client asp.net page as well. ??It simply creates web service object and access its methods.As I am using a file contents to load a page, so I am concerned if it can create trouble as well ?? . Although I have used FileShare.ReadWrite in it.

View 2 Replies

WCF / ASMX ::access The Client's Credentials Inside A WCF Service?

Jan 26, 2011

I have a silverlight application that uses WCF service and i need to provide windows authentication using wcf.In order to achieve this i am trying to retrieve the client's credentials (windows credentials)inside wcf.

View 1 Replies

WCF / ASMX :: Can Access Referenced Web Service From Web Form Code Behind But Not From A Class In The Same Web

Jun 16, 2010

Web service is referenced fine (called "tuWs") and I can refer to it in standard web form code behind:

Dim myWs As tuWebSvc.tuWs = New tuWebSvc.tuWs

View 3 Replies

WCF / ASMX :: Access/pass Parameters To A Web Service WITHOUT A (general) Form?

May 15, 2010

I am a newbie to ASP.NET (but not to C#)I have a project I am developing that may seem unconventional at this point but it is a project that I hope to eventually expand and provide a new type of service on the internet. Currently the project makes use of an Excel spreadsheet that is generated by another application I wrote. Basically the spreadsheet is an index to a specific type of file that exists on a host computer and the files are directly linked from within the excel document. When the link is clicked it opens the file using the operating system default program which then processes the file (this takes some time).

This is fine and dandy but when I click on another file, the default program immediately stops processing one file and opens the latest submission and thus interrupting the previous job. To prevent this I am now writing a queuing application. Here is where ASP.NET comes in. I do not want the link to open the queuing application with the file to add into the queue as a parameter because that pops one or more nnoying/scary "you are opening an executable" dialogs and because I want to be able to access the queuing service from a remote computer, and possibily in the future over the web. Instead I am trying to use an ASP.NET service application that will accept the name of a file as a parameter, access the external queue class (defined in an external dll of which only one universal instance is allowed), and add the request to the queue. Whether or not the table is an excel table or on a web page, using a form in this instance is tedious, not only for me but for a user. I want the user to be able to simply click on an html link and have the file be queued without anything except maybe a confirmation page pop up saying that the file has been queued and it will take x amount of time before the file is finished processing.

My problem is I cannot for the life of me find a way to do this. I have searched the interenet for over a week now looking for a way to call a "WebMethod" using a link and I am getting the impression that it cannot be done. Even when I use a form and try to have the form pass a string (representing the file name) as its "action" it comes up with an application error saying that I am missing the parameter I am trying to pass. Here are some examples of what I have tried:Here an example method I would try to access:

[Code]....

Here is an example of how I tried to access directly by way of a link (which results in an application error: InvalidOperationException)"

[Code]....

View 3 Replies

C# - Android - Access Data In Database Via App?

Jul 22, 2010

I have a Windows web server already set up with a website (unlimited application pools) and I want to be able to access a database on that server via the Android app I'm developing. How can I do this? how this cross-platform (Android/Java to ASP.NET/C#) communication can be done?

(I'm trying to create a leader board or global scoreboard for my Android game on my server.)

View 3 Replies

WCF / ASMX :: HTTP Error: 404, When Attempt To Access Service HTTPS On Different Port?

Feb 9, 2010

we have a situation where we need to host two certificates on the same server and because we can't have two different certificates on the same server running off the same port we have assigned one certificate run through another port, which is 4443.

So the URL to our web app is now....

[URL]

If I punch this into a web browser I can access it fine, however, if I create a web reference using this URL in Visual Studio (2005) it can create the web reference fine and it builds ok. But whenever I call a web method on this service instance I get a HTTP 404 page not found Exception.

Is there any properties I need to set on the web service object to get this to work? I'm confused as to why it's not working.

View 3 Replies

How To Suppress Error Messages When Access Non-existent Web Methods On A .asmx Web Service

Dec 15, 2010

We have a customer who are using HP Web Inspect to test for vulnerabilities in our software.

The web inspect tool is complaining about about error messages being returned when a request such as the following is made [URL].

The ASP.Net framework returns a page with the following text content and a 500 status code.

System.IndexOutOfRangeException: Index was outside the bounds of the array.

[code]....

but the error seems not be an unhandled error and so neither 500 page is shown.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved