title: Angular - Setting value in input text box in another component
body: <p>I am trying to set the value in an HTML input text box which is a part of <code>ComponentA</code> from the typescript code which is a part of <code>ComponentB</code>.</p>
  
  <p>Taking a clue from <a href="https://stackoverflow.com/questions/12989741/the-property-value-does-not-exist-on-value-of-type-htmlelement">this</a> SO i tried doing:</p>
  
  <pre><code>(&lt;HTMLInputElement&gt;document.getElementById("name")).value = response.name;
  </code></pre>
  
  <p>But this is not working. Is there anything else i need to take care of?</p>
  
  <p><strong>EDIT:</strong> The element with Id <code>"name"</code> is in ComponentA and the above code that is trying to manipulate that element is in ComponentB</p>