title: Using String variables in xml files (android studio)
body: <p>So I try to show the String variable in GUI that I inherit from a parent activity.</p>
  
  <p>This is my xml code</p>
  
  <pre><code>&lt;EditText
      android:layout_width="fill_parent"
      android:layout_height="wrap_content"
      android:layout_marginTop="5dp"
      android:inputType="text"
      android:textStyle="italic"
      android:id="@+id/Edit_Title_Update"
      android:text="@string/updating_title"/&gt;
  </code></pre>
  
  <p>This is my String definition</p>
  
  <pre><code> &lt;string name="updating_title"&gt; %s &lt;/string&gt;
  </code></pre>
  
  <p>This is how I try to put date into the String</p>
  
  <pre><code>    String updating_title = getString(R.string.updating_title, show_title);
      Log.e("MyTag","Here2 "+updating_title);
  
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_update__diary);
  </code></pre>
  
  <p>In the console I can see the variable is correct</p>
  
  <pre><code>01-05 10:19:29.767    2849-2849/com.example.wenhaowu.diaryproject E/MyTag﹕ Here2 Happy
  </code></pre>
  
  <p>But In the emulator the String remains the same </p>
  
  <p><img src="https://i.stack.imgur.com/aVqNO.png" alt="enter image description here"></p>
  
  <p>What is the problem and how can I fix it? Thank you.</p>