title: shtDestination based on referenced cell
body: <p>this might be quick for someone who knows so I will appreciate any help...</p>
  
  <p>I have this code:</p>
  
  <pre><code>  Dim shtSource As Worksheet
    Dim shtDestination As Worksheet
    Dim nSourceRow As Long, nDestRow As Long
  
  
    Set shtSource = Sheets("Forecast Opex")
    Set shtDestination = Sheets("Opex Pers Sala Admi")
  
  
      nSourceRow = 46
  
      For nDestRow = 2 To 97
  
          shtDestination.Cells(nDestRow, 3) = shtSource.Cells(nSourceRow, 2).Value 'NewForecast
  
          nSourceRow = nSourceRow + 1
  
      Next nDestRow
  </code></pre>
  
  <p>... and works just fine... the thing is that I need to make the Sheet named "Opex Pers Sala Admi" to change based on the name located in another cell (Ex. H5). The content in that cell varies depending upon certain conditions indicating the Sheet to use ad Destination.</p>
  
  <p>Thank you</p>
  
  <p><strong>UPDATE</strong> from comment</p>
  
  <pre><code>Sub Update_Click() 
      Dim shtSource As Worksheet 
      Dim shtDestination As Worksheet 
      Dim nSourceRow As Long, nDestRow As Long 
  
      Set shtSource = Sheets("Base") 
      Set shtDestination = Sheets(Sheets("Base").Range("L21")) 
  
      '...
  End Sub
  </code></pre>