I want to get a resource id of an android resource that I have saved in /res/raw folder.
The use -
1) I am passing the name of the resource to the class an
You should be able to get the resource id with getIdentifier() :
getIdentifier()
int id = this.getResources().getIdentifier("xyz", "raw", this.getPackageName());