Jeresam515 | 21 May 23:50
Picon

How can I send an image from an sql database to an android client?

I'm trying to send an image from an sql database to an android client. I'm doing this by way of a php middleman. The code stops working due to a null returning of the method below. My php code(works fine to encode image into base64(decoded the encoding and it worked)):

<?php
   
//get image
   
function ob_base64_encode($c) {
    $a
=base64_encode($c);
    $arr
= array('base64' => $a);
     
return json_encode($arr);
   
}
    $image
=resize(48,80,$image);
   
// And pass its name as a string
    ob_start
('ob_base64_encode');
    imagepng
($image);
    ob_end_flush
();
?>

My android code:

public static Bitmap getIm(String IP, int height, int width)
{
   
ArrayList<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>();
//Network queries and gets response(works)
   
String result = Network.getResponse(IP, nameValuePairs);
//manually decode string since for some reason JSON decode won't work(also works)
String r=result.split(":\"")[1];
r
=r.split("\"")[0];
//decode string
   
byte[] decodedString = Base64.decode(r, Base64.DEFAULT);
   
Bitmap decodedByte = BitmapFactory.decodeByteArray(decodedString, 0, decodedString.length);
   
return decodedByte;
//returns null
   
}

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
John | 21 May 20:11
Picon
Favicon

Your Version of Market May be out of Date

I'm trying to run the billing sample Dungeon app on an old HTC Hero
test phone. I get the message that says, "This app cannot connect to
Market. Your version of Market may be out of date."

I opened the Market app and it does not update to the latest version.
It does show apps, so I assume I am connected to the market. But it is
through Wifi not Cellular service.

It seems that I am unable to bind to the market service because the
Market is out of date.

What can I do to bind to this service?

--

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Irfan | 21 May 18:35
Picon

how to send SMTP message from an android app to a web application

hi guys


i am developing an emergency system that consist of an android app and a web application, i need to sent a alert message from my andoid app that contain some msg when the alert button was pressed in ma android app to web application via SMTP, i want ur  guidence about how the coding stuff for that messaging will be code
please help me on this stuff

thanks and regards
irfan 
CSE final yer
UWU  

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
Ashintha Rukmal | 21 May 17:47
Picon

Spinner Help

Hi,,
I'm new to android developing.. I'm trying to make a simple app that
contains 5 spinners. When I select one item in a spinner I want to
auto select other spinner items that equals to selected item position.
I used setOnItemSelected listner and it worked for the 1st spinner.
But when I select item in another spinner nothing will happen..
here's my code for 1st two spinners. Any solution????

spinner.setOnItemSelectedListener(new OnItemSelectedListener() {
public void onItemSelected(AdapterView<?> parentView, View
selectedItemView, int position, long id) {
int pos1=spinner.getSelectedItemPosition();
spinner1.setSelection(pos1);
spinner2.setSelection(pos1);
spinner3.setSelection(pos1);
spinner4.setSelection(pos1);
}

public void onNothingSelected(AdapterView<?> arg0) {
}
});

spinner1.setOnItemSelectedListener(new OnItemSelectedListener() {
public void onItemSelected(AdapterView<?> parentView, View
selectedItemView, int position, long id) {
int pos2=spinner.getSelectedItemPosition();
spinner.setSelection(pos2);
spinner2.setSelection(pos2);
spinner3.setSelection(pos2);
spinner4.setSelection(pos2);
}

public void onNothingSelected(AdapterView<?> arg0) {
}
});

--

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Chuck Krutsinger | 21 May 17:05
Picon

junit.extensions classes

The source for android-sdk 10 includes junit.extensions under
android-10/external/junit/src/junit/extensions/, but android.jar for
sdk 10 does not have that package in it.  Anyone know why?  Have I
installed something incorrectly?  I want to use TestSetup class from
junit.extensions.

--

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Dan Uff | 21 May 17:03
Picon
Gravatar

Eclipse errors coming out from no where???

Hi all,

I am developing an Android app and everything was working fine yesterday.  Now, when I go back into the app, and try to run it, I get the following errors:

setContentView(R.layout.contactlanta);


[R cannot be resolved or is not a variable]


Button back = (Button) findViewById(R.id.backbutton);


[R cannot be resolved or is not a variable]


Likewise, this error is appearing in ALL of my four View files.  The problem seems to be in the AVD Simulator because I got it to run once or twice today, now I am back to these errors.


I also tried to run the same app on different machines (Macs) and still get the same errors.


All of the code IS correct because (like I said before) it ran fine yesterday.


Any ideas???


Dan Uff

danny.uff <at> gmail.com


--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
lcs_godoy | 21 May 16:37
Picon

Change time/date

Hi all,


Is there a way to change time and date without root access on android?

Thanks.

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
Greenhand | 21 May 15:48
Picon

android configuration change asynctask

    I read the thread "AsyncTask and screen rotation" in this group. I
would like to know further about "no messages will be processed
between onRetainNonConfigurationInstance() to
the following onCreate()" under the hood, replied by Dianne Hackborn.
If reading some Android source code is needed, guidelines or file
names are appreciated. I have never read the source before.
    I have tried to reply to the thread but I cannot reply to the
thread. Therefore, I create a new one here.

--

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

arun kumar | 21 May 14:38
Picon

pull to refresh in horizontal listview

Hello all,

I want Pull to refresh in horizontal list view. Anybody please help me!!!! I already try pull to refresh from top to bottom. it works fine. but i need horizontal listview

--
WITH REGARDS
ARUN KUMAR P D
+91-9994794759

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
sunny | 21 May 13:51
Picon

How to resume on previous activity after finishing the newly launched activity

I have an activity running as a service and I start a new activity
through it and after completion a task i closed this activity calling
the finish() method...but my previous activity stops ,can u please
help me how can i resume my previous activity after closing the newly
launched activity...
one thing more I called new activity from the thread of infinite loop.
plz help me with some peace of codes...

--

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Sivasankar K | 21 May 13:48
Favicon

Problem in calling sms application in android 3.0 and above

Following is the piece of code by which i am trying to open the android device default sms application with message and number to be prefilled

String uri = "smsto:4162315";
String body = "hiiiiiiiiiiiiiiiiiiiiiiiiiiii";
Intent sendIntent = new Intent(Intent.ACTION_SENDTO);
                sendIntent.addCategory(Intent.CATEGORY_DEFAULT);
                sendIntent.setType("vnd.android-dir/mms-sms");
                sendIntent.setData(Uri.parse(uri));
                sendIntent.putExtra("sms_body", body);
                sendIntent.putExtra("compose_mode", true);
                startActivity(sendIntent);


when i run this code in android 4.0 emulator the sms application opens with the data prefilled but when in run in device i am getting only the body and not the number.

when i check it with android 3.0, it is to be vice versa, the number gets filled and body is been empty.

Does anyone know the solution for this problem?


--
K Siva Sankar

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers <at> googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe <at> googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Gmane