CSV to Excel to print daily report. How to set default printin mar

  • Thread starter -K- The One And Only
  • Start date
K

-K- The One And Only

Hello,
I have a program that needs to generate reports on a daily basis.
It:
1. Runs Excel
2. Opens XXX1.csv
3. Prints from Excel
4. Exit from Excel
I would like to set default Printing Margins from Excel.
How do I achieve this?
Are there any other ways besides setting a default customized template for
when Excel starts up?

Thank you,
-K-
 
J

JE McGimpsey

-K- The One And Only said:
Oh, I forgot to mention that the csv filename gets replaced everyday. For
instance, on monday it would be XXX1.csv , on tuesday it would be XXX2.csv
and so on..

Would it then reset to xxx1.csv the following Monday?
 
K

-K- The One And Only

JE McGimpsey said:
Would it then reset to xxx1.csv the following Monday?

-----------------------------------------------------------------------

Well, the program has just been modified. How it works now is that, the CSV
filename remains the same, however it will be overwritten everyday when
printing.

Thanks,
-K-
 
J

JE McGimpsey

-K- The One And Only said:
Well, the program has just been modified. How it works now is that, the CSV
filename remains the same, however it will be overwritten everyday when
printing.

That makes things much easier - just record a macro in which you read in
the CSV file, set the margins, and print.

Reading the CSV file via Data/Get External Data/Import text file... will
give you options for how each column is to be interpreted.
 
K

-K- The One And Only

JE McGimpsey said:
That makes things much easier - just record a macro in which you read in
the CSV file, set the margins, and print.

Reading the CSV file via Data/Get External Data/Import text file... will
give you options for how each column is to be interpreted.
-------------------------------------------------------------------------------

Thank you for your help so far.

I manage to record a macro and save it as a personal one, so all I have to
do now is to get my program to run excel, and run the macro right?

s there a default code to call the macro, or does it differ depending on the
program that I am using?

Thanks,
-K-
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top