Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Import data and macro
I have a spreadsheet that uses a web query to gather data. Everyday I
refresh this query and copy and paste the date it imports into another tab. I do not overwrite the data from previous days. I just copy and paste the data below the previous days. Is there some way I can have excel do this automatically? Maybe some kind of macro? Thanks. |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Import data and macro
I do this all the time for myself and clients. Just determine the next available row in the destination sheet and copy to that lr=sheets("dest").cells(rows.count,"a").end(xlup). row+1 range("myrange").copy sheets("dest").range("a" & lr) or with sheets("dest") lr=.cells(.rows.count,"a").end(xlup).row+1 range("myrange").copy .range("a" & lr) end with -- Don Guillett Microsoft MVP Excel SalesAid Software "Jambruins" wrote in message ... I have a spreadsheet that uses a web query to gather data. Everyday I refresh this query and copy and paste the date it imports into another tab. I do not overwrite the data from previous days. I just copy and paste the data below the previous days. Is there some way I can have excel do this automatically? Maybe some kind of macro? Thanks. |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Import data and macro
Don, I am not very familiar with macro's. Is that a formula I should put in
in the destination cell or is that something I need to incorporate into the macro? Thanks for the help. "Don Guillett" wrote: I do this all the time for myself and clients. Just determine the next available row in the destination sheet and copy to that lr=sheets("dest").cells(rows.count,"a").end(xlup). row+1 range("myrange").copy sheets("dest").range("a" & lr) or with sheets("dest") lr=.cells(.rows.count,"a").end(xlup).row+1 range("myrange").copy .range("a" & lr) end with -- Don Guillett Microsoft MVP Excel SalesAid Software "Jambruins" wrote in message ... I have a spreadsheet that uses a web query to gather data. Everyday I refresh this query and copy and paste the date it imports into another tab. I do not overwrite the data from previous days. I just copy and paste the data below the previous days. Is there some way I can have excel do this automatically? Maybe some kind of macro? Thanks. |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
Import data and macro
Don,
Email sent. Thank you very much. "Don Guillett" wrote: It is part of a macro. Send me a workbook (to the address below) along with very detailed instructions as to what you need. Also send snippets of these posts so I will know where it came from. -- Don Guillett Microsoft MVP Excel SalesAid Software "Jambruins" wrote in message ... Don, I am not very familiar with macro's. Is that a formula I should put in in the destination cell or is that something I need to incorporate into the macro? Thanks for the help. "Don Guillett" wrote: I do this all the time for myself and clients. Just determine the next available row in the destination sheet and copy to that lr=sheets("dest").cells(rows.count,"a").end(xlup). row+1 range("myrange").copy sheets("dest").range("a" & lr) or with sheets("dest") lr=.cells(.rows.count,"a").end(xlup).row+1 range("myrange").copy .range("a" & lr) end with -- Don Guillett Microsoft MVP Excel SalesAid Software "Jambruins" wrote in message ... I have a spreadsheet that uses a web query to gather data. Everyday I refresh this query and copy and paste the date it imports into another tab. I do not overwrite the data from previous days. I just copy and paste the data below the previous days. Is there some way I can have excel do this automatically? Maybe some kind of macro? Thanks. |
#6
Posted to microsoft.public.excel.misc
|
|||
|
|||
Import data and macro
Use this
Sub copyvalues() dlr = Sheets("Odds").Cells(Rows.Count, "a").End(xlUp).Row + 1 'MsgBox dlr With Sheets("Pinny") slr = Application.CountA(.Columns("c")) - 1 'MsgBox slr ..Range(.Cells(1, "o"), .Cells(slr, "q")).Copy Sheets("Odds").Cells(dlr, 1).PasteSpecial Paste:=xlPasteValues Application.CutCopyMode = False End With End Sub -- Don Guillett Microsoft MVP Excel SalesAid Software "Jambruins" wrote in message ... Don, Email sent. Thank you very much. "Don Guillett" wrote: It is part of a macro. Send me a workbook (to the address below) along with very detailed instructions as to what you need. Also send snippets of these posts so I will know where it came from. -- Don Guillett Microsoft MVP Excel SalesAid Software "Jambruins" wrote in message ... Don, I am not very familiar with macro's. Is that a formula I should put in in the destination cell or is that something I need to incorporate into the macro? Thanks for the help. "Don Guillett" wrote: I do this all the time for myself and clients. Just determine the next available row in the destination sheet and copy to that lr=sheets("dest").cells(rows.count,"a").end(xlup). row+1 range("myrange").copy sheets("dest").range("a" & lr) or with sheets("dest") lr=.cells(.rows.count,"a").end(xlup).row+1 range("myrange").copy .range("a" & lr) end with -- Don Guillett Microsoft MVP Excel SalesAid Software "Jambruins" wrote in message ... I have a spreadsheet that uses a web query to gather data. Everyday I refresh this query and copy and paste the date it imports into another tab. I do not overwrite the data from previous days. I just copy and paste the data below the previous days. Is there some way I can have excel do this automatically? Maybe some kind of macro? Thanks. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Import Data with Macro or VBA | Setting up and Configuration of Excel | |||
Import Data Excel Macro | Excel Discussion (Misc queries) | |||
in an excel macro can you import data from word into a cell? | Excel Discussion (Misc queries) | |||
import data with macro | Excel Discussion (Misc queries) | |||
import data using macro | Excel Discussion (Misc queries) |