public String getString(String id)
	{
		Context targetContext = instrumentation.getTargetContext(); 
		String packageName = targetContext.getPackageName(); 
		int viewId = targetContext.getResources().getIdentifier(id, "string", packageName);
		if(viewId == 0){
			viewId = targetContext.getResources().getIdentifier(id, "string", "android");
		}
		return getString(viewId);		
	}
public String getString ( String id ) { Context targetContext = instrumentation . getTargetContext ( ) ; String packageName = targetContext . getPackageName ( ) ; int viewId = targetContext . getResources ( ) . getIdentifier ( id , "string" , packageName ) ; if ( viewId == 0 ) { viewId = targetContext . getResources ( ) . getIdentifier ( id , "string" , "android" ) ; } return getString ( viewId ) ; }
Returns a localized string

@param id the resource ID for the string
@return the localized string