title: Copy from autofiltered range with hidden columns doesn't include hidden cells' content
body: <p>My goal is to create a macro that inserts a blank row just above a user-selected cell or row and copies formulas from the selected row into the new inserted row.  Only formulas are to be copied, not constants.   Cells with constant values in the copied row are left blank in the inserted row.</p>
  <p>Code is pretty basic.  Here it is:</p>
  <pre><code>Sub InsertLine()
  
  Selection.EntireRow.Insert
  Selection.Offset(1, 0).EntireRow.copy Selection.EntireRow
  Selection.EntireRow.SpecialCells(xlCellTypeConstants).ClearContents
  
  End Sub
  </code></pre>
  <p>This works great in all but one situation.<br />
  If the range contains both an activated auto-filter <strong>and</strong> hidden columns, then the content of the hidden cell on the copied row does not get selected by the copy method and is hence not transferred to the inserted line.
  If the range is only auto-filtered <strong>or</strong> only has hidden columns, then all works good.</p>
  <p>This behavior is well documented <a href="http://social.msdn.microsoft.com/Forums/office/en-US/206e9548-66e4-4dfc-ac6b-2203dd60fbc4/bug-copy-from-autofiltered-range-with-hidden-columns-doesnt-include-hidden-cells-content?forum=exceldev" rel="nofollow noreferrer">here</a> but no solution is offered.
  I haven't found anything else on the web.</p>
  <p>This behavior is identical when performing cut-and-paste (ctrl-C/ctrl-V ) operations manually directly from the spread sheet.<br />
  So I would say it's not a VBA issue.  But the solution may lie with VBA.<br />
  Can anyone offer any solutions or workarounds?</p>