Alain wrote:
> Mark,
> 
> I tried your suggestion with this code, but this throws an exception.
> 
> String varName = "R.array."+itemName[listaa_position];
>       int itemsid=getResources().getIdentifier(varName, null,
> getPackageName());
>       items = getResources().getStringArray(itemsid);
> 
> The itemName[] are  string-array struct in the res/values/arrays.xml
> 

Try getIdentifier(itemName[...], "array", getPackageName());

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Android 2.0 Programming Books: http://commonsware.com/books

-- 
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@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to