404 Error

by cuil yahoo » Mon, 21 Feb 2011 01:55:44 GMT


Sponsored Links
 Can somebody please point out the error in the following code ? i am always
getting a 404 not found error.

String url =
https://spreadsheets.google.com/feeds/spreadsheets/private/full/?oauth_signature=2343243D&oauth_consumer_key=anonymous&oauth_version=1.0&oauth_signature_method=HMAC-SHA1&oauth_timestamp=12981233697&oauth_nonce=somthing...<https://spreadsheets.google.com/feeds/spreadsheets/private/full/?oauth_signature=veCGhtgHZ9IdVg%3D&oauth_consumer_key=anonymous&oauth_version=1.0&oauth_signature_method=HMAC-SHA1&oauth_timestamp=12981233697&oauth_nonce=231234123345223760713>(
i have changed the url a bit for reasons.. )

            HttpGet get = new HttpGet(url);

            HttpClient client = new DefaultHttpClient();
            HttpResponse response = client.execute(get);


            if (response.getStatusLine().getStatusCode() ==
HttpStatus.SC_OK) {

}

Isn't this the normal way of getting the response to any get call ?



Thanks,


--
Cuil

-- 



RE: 404 Error

by Tommy » Mon, 21 Feb 2011 04:11:37 GMT


 I notice some spaces in the string. You may want to replace those with %20
and see if it makes a difference.

 

From: android-developers@googlegroups.com
[mailto:android-developers@googlegroups.com] On Behalf Of cuil yahoo
Sent: Sunday, February 20, 2011 12:55 PM
To: android-developers@googlegroups.com
Subject: [android-developers] 404 Error

 

Can somebody please point out the error in the following code ? i am always
getting a 404 not found error.

String url = 
https://spreadsheets.google.com/feeds/spreadsheets/private/full/?oauth_signa
ture=2343243D
<https://spreadsheets.google.com/feeds/spreadsheets/private/full/?oauth_sign
ature=veCGhtgHZ9IdVg%3D&oauth_consumer_key=anonymous&oauth_version=1.0&oauth
_signature_method=HMAC-SHA1&oauth_timestamp=12981233697&oauth_nonce=23123412
3345223760713>
&oauth_consumer_key=anonymous&oauth_version=1.0&oauth_signature_method=HMAC-
SHA1&oauth_timestamp=12981233697&oauth_nonce=somthing... ( i have changed
the url a bit for reasons.. )

            HttpGet get = new HttpGet(url);

            HttpClient client = new DefaultHttpClient();
            HttpResponse response = client.execute(get);


            if (response.getStatusLine().getStatusCode() ==
HttpStatus.SC_OK) {

}

Isn't this the normal way of getting the response to any get call ? 


        
Thanks,


--
Cuil

-- 


-- 


Sponsored Links


Other Threads

1. MediaPlayer's invoke() & OpenCORE's PlayerExtensionCommand

I thought MediaPlayer's invoke() is for using OpenCORE's
PlayerExtensionCommand.

but when I actually used invoke(), I got an error

  E/MediaPlayer( 1263): invoke failed: wrong state 10

I found that invoke() is supposed to be called between
MediaPlayer.setDataSource() and prepare()

which is quite narrow.

Any reason for this? or I can change this for my own purpose?

-- 
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: 

2. ContentProvider to Spinner results in blank, not empty, list

I'll give that a try, thanks for the tip!



Have a look at this code from android developer guide page (http:// developer.android.com/guide/topics/ui/binding.html) SimpleCursorAdapter adapter2 = new SimpleCursorAdapter(this, android.R.layout.simple_spinner_item, // Use a template // that displays a // text view cur, // Give the cursor to the list adapter new String[] {People.NAME}, // Map the NAME column in the // people database to... new int[] {android.R.id.text1}); // The "text1" view defined in // the XML template You need to map the data column in the database TO the text view u defined in the main.XML or watever ui xml template. As I can see in ur code, projection string arrays has two column name "_id" and "label_strings". But ur int array "[]i" has the only one id "int [] i = {R.id.myspinner};" I assume R.id.myspinner is the textview name. I m a beginner too, and i will try this tutorial myself and get back to u.
--

3. Tebar Pesona :P

4. socket communication between emulator as server and pc as client

5. To develop Android applications with more security and copyright act is it possibl

6. about making charts in android

7. Samsung Galaxy with Froyo