13

I have to download multiple csv reports from the Internet throughout the day, make a tiny change to them, and save the change. Excel adds 3 completely unnecessary dialogs to what should really be a 5-second operation.

  1. It makes you select a file name in a "Save As..." dialog, even though you just want to save the existing file
  2. It makes you confirm the file name, because it thinks you're overwriting the original file
  3. It asks you if you really want to save in the CSV format

Is there a way to kill at least one or two of these dialogs, but ideally all of them? This is completely infuriating.

Matthew S
  • 559
  • 1
  • 5
  • 19
  • 4
    Not a duplicate. This deals with 3 prompts, not just 1. Also, that solution is for 1 file only. The macro has to be run on each new file. My issue is dealing with a large number of files. – Matthew S Feb 03 '14 at 22:51
  • You could use another software such as Notepas++ for this purpose. It lets you handle multiple files in tabs and is much simpler for .csv files. Unless of-course you need any of MS Excel features. – agirish Feb 04 '14 at 01:42
  • I'm open to using other programs, but I need the data displayed as a table instead of a bunch of data, and I need to be able to sort the columns from smallest to largest. Those are the only functions I need. – Matthew S Feb 04 '14 at 01:52
  • [try this](http://stackoverflow.com/questions/11220537/vba-workbooks-close-without-being-prompted-to-if-the-user-wants-to-save) – Raystafarian Feb 04 '14 at 15:41
  • @Raystafarian What's the code they are referring to? I am not familiar with customizing Excel. Where does this code go? – Matthew S Feb 04 '14 at 16:19
  • `Application.DisplayAlerts = False` always does the trick for me in macros. (Remember to set back to true at the end!). EDIT: as referenced in Raystafarian's link. – Andi Mohr Feb 04 '14 at 17:28
  • @AndiMohr Please see my comment above – Matthew S Feb 04 '14 at 18:01
  • @KnocksX press F11 to enter the VBA editor. Double-click `Modules` in the folder menu on the left. You should see the VBA code that tells your macro what to do. Add `Application.DisplayAlerts = False` right at the start of the macro (after the `Sub YourMacroName()` bit). Then before `End Sub` at the end, add `Application.DisplayAlerts = True` to switch alerts back on again. HTH – Andi Mohr Feb 05 '14 at 09:36

1 Answers1

8

I have consulted multiple sources, and there is no fix for Microsoft Office.

However, I installed LibreOffice, and it handles CSV files the exactly correct way. I made LibreOffice the default program for opening CSV files, and the problem is now solved.

Matthew S
  • 559
  • 1
  • 5
  • 19