android - how to get string value using this code -


how string values using this,right return integer value.

 getapplicationcontext(),getresources().getidentifier("please_try_again_"+nativelocalesymbol, "string", getpackagename()); 

getidentifier returns resource identifier why int. using id can resource

 int resid = getapplicationcontext().getresources().getidentifier("please_try_again_"+nativelocalesymbol, "string", getpackagename());  getapplicationcontext().getresources().getstring(resid) 

Comments

Popular posts from this blog

html - Cut text on left side inside button while centering -

java - Last square of 8x8 grid not drawn, using two nested FOR loops -

What design pattern is this code in Javascript? -