Forum Cross Platform with Xamarin

Announcement:

The Xamarin Forums have officially moved to the new Microsoft Q&A experience. Microsoft Q&A is the home for technical questions and answers at across all products at Microsoft now including Xamarin!

To create new threads and ask questions head over to Microsoft Q&A for .NET and get involved today.

Return id of resource, if i know name of resource

Hiton4ikHiton4ik UAMember
edited October 2012 in Cross Platform with Xamarin

How i can return id of resource, if i know name of resource?

Something like this:

String mDrawableName = "myappicon";

int resID = getResources().getIdentifier(mDrawableName , "drawable", getPackageName());

Posts

Sign In or Register to comment.