I have around 200 cells in the range, not just the 4.
Any other solution.
"Tom Ogilvy" wrote:
> Sub Refresh()
>
> Range("C6,C11,C1124,C29").FormulaR1C1 = _
> "=VLOOKUP(R[-3]C,'Desk Allocation'!R2C3:R130C6,2,FALSE)"
> End Sub
>
> --
> Regards,
> Tom Ogilvy
>
>
> "Rajula" <(E-Mail Removed)> wrote in message
> news:A06C777B-E35D-48D3-BEA4-(E-Mail Removed)...
> >I did a real stupid code. Just recorded a macro for double clicking the
> >cells
> > with look-up. And then copied the code for other cells. Now i run this
> > macro
> > to refresh.
> > IS there a easier or smaller code to replace this. This code is really
> > STUPID.
> >
> > Sub Refresh()
> > '
> > ' Refresh Macro
> > ' Macro recorded 13/10/2006 by XXX
> > '
> >
> > '
> > Range("C6").Select
> > ActiveCell.FormulaR1C1 = _
> > "=VLOOKUP(R[-3]C,'Desk Allocation'!R2C3:R130C6,2,FALSE)"
> > Range("C11").Select
> > ActiveCell.FormulaR1C1 = _
> > "=VLOOKUP(R[-3]C,'Desk Allocation'!R2C3:R130C6,2,FALSE)"
> > Range("C1124").Select
> > ActiveCell.FormulaR1C1 = _
> > "=VLOOKUP(R[-3]C,'Desk Allocation'!R2C3:R130C6,2,FALSE)"
> > Range("C29").Select
> > ActiveCell.FormulaR1C1 = _
> > "=VLOOKUP(R[-3]C,'Desk Allocation'!R2C3:R130C6,2,FALSE)"
> >
> > End Sub
> >
> > "Carim" wrote:
> >
> >> Close Excel and re-open it ...
> >>
> >> Carim
> >>
> >>
>
>
>
|