Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Importing data
hi
I would like to import data from the web and although this is quite simple in Excel 2003 the new data (that comes in upon refresh) replaces the old. I was wondering if there is a way to keep previous history of the data, make Excel fill in adjacent cells with the new data for example. Thanks for taking the time to read this George |
#2
|
|||
|
|||
hi,
if you are using Microsoft query, the answer would be no. The Micorsoft query becomes a named range in excel that is linked to the query. by desing it expands and contracts at refresh to accommidate new data. I think to accomplish what you want you might new a macro to copy the data prior to refresh. this is a little more complicated than a simple copy but if you use the copy command, you would be coping the MSQ too. Sub macSetRange() Dim rng As Range Dim rng1 As Range Dim rcnt As Long Dim ccnt As Long Set rng = Range(Range("A1"), Range("A1").End(xlDown).Offset (0, 1))'set the 1 to the number of columns you have 'rng.Select rcnt = rng.Rows.Count - 1 ccnt = rng.Columns.Count - 1 Set rng1 = Range(Range("K1"), Range("K1").Offset(rcnt, ccnt)) rng1.Value = rng.Value rng.select selection.querytable.refresh Backgroundquery:=false end sub -----Original Message----- hi I would like to import data from the web and although this is quite simple in Excel 2003 the new data (that comes in upon refresh) replaces the old. I was wondering if there is a way to keep previous history of the data, make Excel fill in adjacent cells with the new data for example. Thanks for taking the time to read this George . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Importing .txt data files increases .xls file size | Excel Discussion (Misc queries) | |||
Importing Data | Excel Discussion (Misc queries) | |||
Pulling data from 1 sheet to another | Excel Worksheet Functions | |||
Importing Data From Another Spreadsheet | Excel Discussion (Misc queries) | |||
How to import a path/filename when importing data into an XML list | Excel Worksheet Functions |