java - Create an alert's message out of < 2 R.string.id texts -


i'm creating alert should display variable inside display message.

so i've created r.string.dialog_message1 , r.string.dialog_message2 put before , variable. achieved:

 builder.setmessage(r.string.dialog_message1 + lastones + r.string.dialog_message2)             .settitle(r.string.dialog_title ); 

i no errors until runtime process.

it displays:

"submit query" instead own mixed message, ideas?

your code should like:

builder.setmessage(getstring(r.string.dialog_message1) + lastones + getstring(r.string.dialog_message2)).settitle(getstring(r.string.dialog_title)); 

Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

android - Keyboard hides my half of edit-text and button below it even in scroll view -