Simple macro?

theta

Well-known Member
Joined
Jun 9, 2009
Messages
960
Hi,

I have a system that exports a CSV to the screen. I need a macro that will :

> Copy the contents of the CSV file
> Open a saved Excel file
> Paste the CSV into the DATA tab of the opened Excel file

Will this need to be stored into the personal workbook of each user so that they can run it from empty excel??

Any ideas?

Regards

T
 

Some videos you may like

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.

BrianB

Well-known Member
Joined
Feb 17, 2003
Messages
8,127
Don't understand what you mean by
exports a CSV to the screen

most applications will make a .csv *file* on disk that can be imported into Excel.

It doesn't matter where a macro is stored (ie. any workbook).
In this case I would probably store it in the workbook that contains the data from the .csv file and use it to make updates.
 

theta

Well-known Member
Joined
Jun 9, 2009
Messages
960
As in...excel opens, and CSV data is inserted...but workbook not saved. Want to be able to run a macro at this point to copy the data in current worksheet to the data tab of the saved worksheet...?

Any ideas?

Regards

T
 

Watch MrExcel Video

Forum statistics

Threads
1,127,303
Messages
5,623,865
Members
415,997
Latest member
ragomes

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top