 <p>You can access a string resource through <code>R.string.mystring</code> or <code>@string/mystring</code>. It is not required that string must be in the file <code>strings.xml</code>. It can be in another file, e.g. <code>mystrings.xml</code>. However, the only requirement is that the file <code>mystrings.xml</code> must be in the directory <code>res/values/</code>.</p> <p><strong>Besides</strong>, you cannot have two string resources with the same name, and it doesn't matter whether they are in different XML files. If you try that in Android Studio, you will get the following error: <code>Error:Execution failed for task ':app:mergeDebugResources'.</code></p>