Tuesday, 15 September 2015

excel - Select cells and replace contents with a formula -


This is my first post, I have already done very limited VBA, so please forgive any mistake!

I want to change the contents of many cells with the formula of each cell.

All cells are in the same column and currently there is a different formula that I have a new thread.

So far, I am able to select the cells, but instead of content with the formula, I am not getting rid of! (These are many more cells than below, this is an example).

  Sub SelectionContactCell () selects the union (range ("A2, A5, A8, A11") which requires all changes.  
 < I want to select the following cells:  A11, A14, A17    

and change your content to: = B2, = B5, = B8, = B11, = B14, = B17

Thank you for your help

< P>

Try this:

  sub-testing () Dim specificCells as Range specific seals = union set (sheet 4 .Range ("A2, A5, A8, A11"), Sheet 4 Category ("A14, A17")) Specific Seals.formulaar1c1 = "= indirect (" rc [1] ", incorrect)" and all  

No comments:

Post a Comment