ActiveSheet.UsedRange.Rows.Count falscher Wert
22.03.2006 09:25:13
Markus
ActiveSheet.UsedRange.Rows.Count bringt bei mir immer Falscher Wert..
Importiere txt file mit 12000 zeilen...
zurück bekomm iche 58xxx .....
was läuft da schief? danke
With ActiveSheet.QueryTables.Add(Connection:=strConnect, Destination:=Range("A2"))
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = False
.RefreshStyle = xlInsertDeleteCells
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True
.RefreshPeriod = 0
.TextFilePromptOnRefresh = False
.TextFilePlatform = 850
.TextFileStartRow = 1
.TextFileParseType = xlFixedWidth
.TextFileTextQualifier = xlTextQualifierDoubleQuote
.TextFileConsecutiveDelimiter = False
.TextFileTabDelimiter = True
.TextFileSemicolonDelimiter = False
.TextFileCommaDelimiter = False
.TextFileSpaceDelimiter = False
.TextFileColumnDataTypes = Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, _
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1)
.TextFileFixedColumnWidths = Array(4, 4, 4, 6, 10, 18, 3, 13, 13, 13, 13, 13, 13, 13, 13, _
13, 13, 13, 13, 13, 13, 13, 9, 9, 9, 1, 1, 1, 18, 9, 3)
.TextFileTrailingMinusNumbers = True
.Refresh BackgroundQuery:=False
End With
lngDatensaetze = ActiveSheet.UsedRange.Rows.Count