Use your own strings.
On Wed, Oct 13, 2010 at 1:53 AM, xZise <[email protected]> wrote:
> Hello, I want to display a simple dialog to ask if somebody has done
> something.
>
> public class YesNoTest extends Activity {
> /** Called when the activity is first created. */
> @Override
> public void onCreate(Bundle savedInstanceState) {
> super.onCreate(savedInstanceState);
> setContentView(R.layout.main);
>
> final AlertDialog.Builder b = new AlertDialog.Builder(this);
> b.setIcon(android.R.drawable.ic_dialog_alert);
> b.setTitle("Hello World");
> b.setMessage("Did you done your homework?");
> b.setPositiveButton(android.R.string.yes, null);
> b.setNegativeButton(android.R.string.no, null);
> b.show();
> }
> }
>
> Normally I would answer "Yes" or "No", but the dialog only shows "OK"
> and "Cancel". Is it easily possible to change it to "Yes"/"No" with
> localization?
>
> Sincerely
> xZise
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]<android-developers%[email protected]>
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
--
Kumar Bibek
http://techdroid.kbeanie.com
http://www.kbeanie.com
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en