Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
#1 I'm not a programmer, just learning this stuff so please excuse the
"stupid" questions. Pleae explain the reason or fix in plain english so I can understand and learn from this. I'm pulling data from from the internet using the following WEBQUERY: as a gosub routine. It works perfectly every single time! But when I add either of the two following commands, I get the runtime error "5" error. pgname.Range("A1:R100").Delete (xlShiftUp) pgname.Range("A1:R100").Delete When I remove the code the WEBQUERY: works fine without a hitch. Please help me i) understand why this is causing a problem and ii) how can I get the specified range cleared before the WEBQUERY: routine runs. By the way, the ...... broken code excerpt ..... WEBQUERY: pgname.Range("A1:R100").Delete (xlShiftUp) '<-- executes! With pgname.QueryTables.Add(Connection:= _ '<-- errors! "URL;" & mwURL & scantype & "" _ , Destination:=rng) .Name = scantype ... .. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Run-time error "1004" Select method of range class failed | Excel Discussion (Misc queries) | |||
Macro that runs entered value through "low" and "high" range | Excel Programming | |||
"Subscript out of range" error for: Workbooks("Test1.xls").Save | Excel Programming | |||
RunTime Error "1004" QueryTable is Invalid | Excel Programming | |||
"Run-time error '1004'" Method 'Range' of object '_global' failed. | Excel Programming |