Integrate a Vlookup function in to a macro

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have no clue how to add this vlookup function to a macro.

The formula is
=VLOOKUP(A6,'[Commissions Master
Summary2007-04-04-08-30-25.xls]Sheet1'!$1:$65536,11,FALSE)

Its working great if I keep copy pasting the formula but I want to take it a
step ahead and automate it.
 
I have no clue how to add this vlookup function to a macro.

The formula is
=VLOOKUP(A6,'[Commissions Master
Summary2007-04-04-08-30-25.xls]Sheet1'!$1:$65536,11,FALSE)

Its working great if I keep copy pasting the formula but I want to take it a
step ahead and automate it.

Part of the recording of your macro should be typing vlookup formula.
It will work.. I've done it many time myself.
When you run your macro, make sure that the file that's being
referenced in the vlookup formula is already opened. It will make
your macro run quicker.
 
It is c.formula "=VLOOKUP(A6,'[Commissions Master
Summary2007-04-04-08-30-25.xls]Sheet1'!$1:$65536,11,FALSE)"

or cells(i,j).formula = "=VLOOKUP(A6,'[Commissions Master
Summary2007-04-04-08-30-25.xls]Sheet1'!$1:$65536,11,FALSE)"

Regards
Peter

I have no clue how to add this vlookup function to a macro.

The formula is
=VLOOKUP(A6,'[Commissions Master
Summary2007-04-04-08-30-25.xls]Sheet1'!$1:$65536,11,FALSE)

Its working great if I keep copy pasting the formula but I want to take it a
step ahead and automate it.

Part of the recording of your macro should be typing vlookup formula.
It will work.. I've done it many time myself.
When you run your macro, make sure that the file that's being
referenced in the vlookup formula is already opened. It will make
your macro run quicker.
 
Back
Top