title: Excel: create image from cell range
body: <p>Using Excel VBA, I want to create an image showing the content of a cell. </p>
  
  <ul>
  <li>Manually, I can do this by selecting a cell, clicking on 'copy', selecting another cell, and clicking on 'paste as image'. Then I can select the image and set its formula to <code>=$B$2</code>, for example.</li>
  <li><p>The Macro recorder tells me that this is equivalent to the following code: </p>
  
  <pre><code>Selection.Copy  
  ActiveSheet.Pictures.Paste.Select
  ActiveCell.FormulaR1C1 = "=R[1]C[1]"
  </code></pre></li>
  <li><p>I want to achieve the same without using the copy-paste-select commands. In other words, I would like to create a <code>Picture</code> object with predefined <code>FormulaR1C1</code> property. </p></li>
  <li><p>I tried <code>ActiveSheet.Pictures.Add(Left, Top, Width, Height)</code> but only got <code>Runtime error '1004': No link to paste</code>. I don't understand what this means.</p></li>
  <li><p>I tried <code>ActiveSheet.Pictures.Insert</code> and <code>ActiveSheet.Shapes.AddPicture</code>, but they both require a file name to load an external image file, which is not what I want. </p></li>
  </ul>