Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Runtime error 1004 when trying to insert formula in cells
I have a sheet with some numbers in some cells, while other celles are empty. Now I try to replace the numbers with a certain formula, but it returns a runtime error 1004, Application-defines og obeject-defined error.
The macro looks like this: Sub FyldUdfyldte() Dim Indhold As String Indhold = InputBox("Type needed formula"") For Each c In Selection.Cells If Not IsEmpty(c) Then c.Value = Indhold Next c End Sub The formula looks like this =IF(VLOOKUP($A31,Opslag!$A:$M,F$1,FALSE)0,VLOOKUP ($A31,Opslag!$A:$M,F$1,FALSE),"") "Opslag" is another sheet, from where to get new numbers. Any ideas? Jan |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
unable to protect cells in macro sheet b/c runtime error 1004 | Excel Worksheet Functions | |||
runtime 1004 error on deleting rows with blank cells | Excel Programming | |||
Runtime 1004 error -- insert method of range class failed. | Excel Discussion (Misc queries) | |||
Runtime 1004 error when insert. | Excel Programming | |||
Runtime 1004 error when insert. | Excel Programming |