android email address logcat shows only numbers -


in android app have strings.xml following value:

<string name="email">mail@domain.com</string> 

in main.class have log.e:

log.e("-->", ""+r.string.email); 

the output is:

2131099691

why?

r.string.email string resource id. in order value associated it, need call getresources().getstring() & pass in resource's id argument:

log.e("-->", ""+getresources().getstring(r.string.email)); 

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? -

ruby on rails - Seeing duplicate requests handled with Unicorn -