title: Google script to find and update rows in other sheets by unique ID
body: <p>I have about 4 separate spreadsheets that accepts user input and when the user is finished they push a button to ‘log’ the information on another sheet. All of the spreadsheet entries from user input have a unique ID assigned to them.</p>
  
  <p>What I am trying to do is when the user clicks the button the script searches another sheet for the matching ID and updates Column B to the new value. </p>
  
  <p>Basically like a simple lookup, but instead of returning the value, it updates. </p>
  
  <pre><code>Sheet 1                 Sheet 2
      A       B               A       B 
  1  ID123 | Received  &gt;   1  ID123 | Ordered
  2                        2
  </code></pre>
  
  <p>So as the user changes ID123 in spreadsheet 1 to Received, the button searches for ID123 in spreadsheet 2 and if it exists (it always will), cell b1 in sheet 2 gets updated with the value in B1 in sheet 1. </p>
  
  <p>I did come across another post talking about a <a href="https://stackoverflow.com/questions/38014698/crud-webapp-google-app-script">CRUD web app</a>, but I am thinking that is a bit more complex than what I am looking to do here!</p>
  
  <p>Thank you for any assistance!</p>
  
  <p><strong>EDIT:</strong>
  The button I mentioned is added in via a custom image in which this script will be assigned to.</p>
  
  <p>It might help to add that the 'Starting sheet' will only ever have 1 ID on it. It is the 'destination sheet' that will have multiple ID's, even the same ID repeating multiple times, in which case all matching IDs would need to be updated.</p>
  
  <p><a href="https://i.stack.imgur.com/YN2RR.png" rel="nofollow noreferrer">Sample of Starting Sheet</a> and 
  <a href="https://i.stack.imgur.com/iHwx7.png" rel="nofollow noreferrer">Sample of Destination Sheet</a></p>
  
  <p>As you can see above, in the 'Starting Sheet', ID3 has a Status of "Received". Upon pushing that Submit button, the script would need to find "ID3" in the 'Destination Sheet' and replace whatever text is in the Value column with "Received". So in this example, ID3 is being updated from "Ordered" to "Received".</p>