Thread: Run Time Error
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Run Time Error

I am getting a Run time Error 1004 Method 'Range' of
object'_Global' failed.

Here is my code and I will show the line that the
debugger shows. Any help would be great. Thanks

x = i
y = i - 2
Do Until i = FinalRow

***(This Row) If Not ((Range("E" & y).Value) = (Range("D"
& x).Value)) And Not (x = FinalRow) Then
x = x + 1
End If

If (Range("E" & y).Value) = (Range("D" & x).Value) Then
Call OtherSections(i, x)
Do Until (Range("F" & (i - 1)).Value) = ""
ChildRow = Columns(1).Find(What:=(Range("F" & (i -
1)).Value), LookIn:=xlFormulas).Row
Call OtherSections(i, ChildRow)
Loop
y = i - 2
Else
y = y - 1
End If

Loop


i is the next row that is going to have something pasted
to it.

x is the number of the row as it checks to see if the
value in D equals the value in E

y is another counter in case D never equals E, y moves
the row that E is in up one.

At the end of the called funtion i gets increased by 1.

Thank you very much