Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a macro that is doing a number of things, starting with importing a
txt file. When I try to run it, I get this error: "Run-time Error '-2147417848 (80010108)' Automation Error The object invoked has disconnected from its clients. When I Debug. it goes to the following line within the code ".Refresh BackgroundQuery:=False" I have tried everything I know to fix it (granted, that is not very much). Below is the code. Any help would be appreciated. Thanks in advance. Workbooks.Add With ActiveSheet.QueryTables.Add(Connection:="TEXT;C:\D ata\SALES.TXT", _ Destination:=Range("A1")) .Name = "SALES" .FieldNames = True .RowNumbers = False .FillAdjacentFormulas = False .PreserveFormatting = True .RefreshOnFileOpen = False .RefreshStyle = xlInsertDeleteCells .SavePassword = False .SaveData = True .AdjustColumnWidth = True .RefreshPeriod = 0 .TextFilePromptOnRefresh = False .TextFilePlatform = -536 .TextFileStartRow = 1 .TextFileParseType = xlFixedWidth .TextFileTextQualifier = xlTextQualifierDoubleQuote .TextFileConsecutiveDelimiter = False .TextFileTabDelimiter = True .TextFileSemicolonDelimiter = False .TextFileCommaDelimiter = False .TextFileSpaceDelimiter = False .TextFileColumnDataTypes = Array(2, 1, 1, 1, 1, 1, 1, 1, 1, 1) .TextFileFixedColumnWidths = Array(26, 14, 7, 11, 1, 17, 17, 8, 3) .TextFileTrailingMinusNumbers = True .Refresh BackgroundQuery:=False End With End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Run Time Error 2147417848 - 80010108 method Copy of Object Range F | Excel Programming | |||
Runtime Error '-2147417848 (80010108)' | Excel Programming | |||
Macro does not work after the program has been restarted in excel.Run time error 2147417848 (80010108) Method visible of object_worksheet failed | Excel Programming | |||
Excel Bug: Run-time error '-2147417848 (80010108)' | Excel Programming | |||
Run time error 2147417848(80010108) | Excel Programming |