Dan Nielsen
New Member
- Joined
- Jan 10, 2018
- Messages
- 6
Hi
I have been using a large EXCEL sheet with a lot of VBA. But suddenly a line does not work.. (It has been working for a long time).
I get
Run-time error '1004':
Markeringen er for stor.
(The marked area is to big)
It works but only to 4000 rows, if there more i fails.
I have the same line working in a old version (with more then 6000 rows) of the file, but i have changes so much since
_______________________________________
Rem Udvid ark
Dim RowNo As Long
RowNo = Workbooks("LetOptik").Worksheets("FakturaLinje_DB").Range("A" & Rows.Count).End(xlUp).Offset(3).Row 'RowNo er blevet defineret i Modul1 "Option Explicit Public RowNo As Long"
If RowNo < 5 Then RowNo = 5
Workbooks("LetOptik").Worksheets("Salgsoversigt").Range("A5:BM5").AutoFill Destination:=Workbooks("LetOptik").Worksheets("Salgsoversigt").Range("A5:BM" & RowNo), Type:=xlFillDefault 'Kopier formler til resten af ark.
____________________________________________
I have been using a large EXCEL sheet with a lot of VBA. But suddenly a line does not work.. (It has been working for a long time).
I get
Run-time error '1004':
Markeringen er for stor.
(The marked area is to big)
It works but only to 4000 rows, if there more i fails.
I have the same line working in a old version (with more then 6000 rows) of the file, but i have changes so much since
_______________________________________
Rem Udvid ark
Dim RowNo As Long
RowNo = Workbooks("LetOptik").Worksheets("FakturaLinje_DB").Range("A" & Rows.Count).End(xlUp).Offset(3).Row 'RowNo er blevet defineret i Modul1 "Option Explicit Public RowNo As Long"
If RowNo < 5 Then RowNo = 5
Workbooks("LetOptik").Worksheets("Salgsoversigt").Range("A5:BM5").AutoFill Destination:=Workbooks("LetOptik").Worksheets("Salgsoversigt").Range("A5:BM" & RowNo), Type:=xlFillDefault 'Kopier formler til resten af ark.
____________________________________________