View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Arnold Klapheck Arnold Klapheck is offline
external usenet poster
 
Posts: 42
Default Replacing Code with words using vlookup

Update:
A guy at office said must insert column then could hide column with code
words.

So I updated it to:

Dim intLastRow, intcount As Integer
Dim MyCell, MyRng As Range

intLastRow = [F65535].End(xlUp).Row
intcount = 1

Columns("G:G").Insert Shift:=xlToRight

Set MyRng = Range("G1:G" & intLastRow)

For Each MyCell In MyRng

MyCell.Value = Application.WorksheetFunctions.VLookup("F" & intcount,
Worksheets("Lookup").Range("$A$4:$B$10"), 2, False)
intcount = intcount + 1
Next MyCell

can't run the MyCell.Value line says "Object doesn't support this property
or method" any help would be appreciated.