11 Replies Latest reply on Jun 9, 2016 2:13 AM by Mark Fraser

    Export All Charts to Excel

    Mila T

      All,

      I am beginner in Tableau and my question is: Is it possible to copy/paste or export all charts from Tableau (in Tableau I have 30 Sheets, every sheet contains one graph) in Excel with some macro, query or anything else?

      Every Monday I copy these charts in the same locations in the Excel file and it's pretty annoying to do this manually.

      Is there any easier way for this?

       

      Thank you in advance.

        • 1. Re: Export All Charts to Excel
          Mark Fraser

          Hi Mila

           

          Normally for these kind of activities you would use Tableau Server (specifically tabcmd) to automate routine jobs such as exports to Excel.

          is it possible to automate data export to csv or excel from Tableau View?

          You would create a batch file (.bat) and run it on a scheduler, Windows has one.

           

          To achieve this with Desktop only... hmmm , some kind of macro/ automator such as autolt

           

          Someone will hopefully jump in with a much whizzier way

           

          Cheers

          Mark

          • 2. Re: Export All Charts to Excel
            Mila T

            Sorry, I have Tableau Desktop and really don't understand anything from the link you sent me. Could you explain me on some example how to use this tabcmd?

            • 3. Re: Export All Charts to Excel
              Mark Fraser

              Hi Mila

               

              (I'll keep it simple for ease) Tableau makes 2 main products - Desktop and Server.

              At their most basic Desktop is to create content, and Server is to share content.

              'Automated' exports to Excel = sharing, hence you need Server.

              Manual exports to Excel can be done in either Desktop or Server, as you have been doing in Desktop already.

               

              tabcmd

              Tabcmd is a command line tool for Server which is like a macro.

              You give tabcmd a set of instructions, and it will carry them out, you can automate them, so you can do it over night/ when you're away etc.

              The tabcmd functionality is for Server only.

               

              if you need further help let me know, I personally use both Desktop and Server with tabcmd so have plenty of scripts i can share, but if you haven't got Server, there will be little point, you couldn't use them.

               

              Is that all clear?

               

              Cheers

              Mark

              • 4. Re: Export All Charts to Excel
                Mila T

                Definitely, I need help from you , so if you are ready to explain me or share some scripts with me I am ready. One more info regarding this. I work with 5 regions and that means I have at least 30 charts per region. So, could you imagine to copy/paste more than 150 charts to Excel every Monday?  

                Thanks!

                • 5. Re: Export All Charts to Excel
                  Mark Fraser

                  Hi Mila

                   

                  Happy to share scripts, not a problem. Here is a very basic script -

                   

                  @ECHO OFF

                  ECHO Processing.....

                   

                  cd /D C:\

                  cd C:\tabcmd\Command Line Utility

                  tabcmd logout

                  tabcmd login -s http://ourserver.com -t Default -u mark --password-file pwd.txt

                   

                  tabcmd blah blah blah

                   

                  tabcmd logout

                   

                  ECHO ON

                   

                  What it does -

                  ECHO OFF = stops system messages displaying in the command window, just says Processing...

                  cd /D C:\ = swap directory to the C drive

                  cd C:\tabcmd\Command Line Utility = open the tabcmd utility (note its saved in the C root)

                  tabcmd logout = logout, in case there was a previous session still logged in

                  tabcmd login... = login so our server, default site, me as user, password in a file (for security)

                  Tabcmd blah blah blah = this is where the instructions would go, anything from this list tabcmd Commands  (export for example)

                  Once they are all done, logout, turn the ECHO back on, DONE

                   

                  Hope that's clear, i have other scripts but that will start you off.

                   

                  So, could you imagine to copy/paste more than 150 charts to Excel every Monday?  

                  I can imagine, but I wouldn't want to do it!

                  My comment on this is - are they necessary? Could the information be better displayed and distributed? I suspect it probably could.

                  To understand - Tableau wants to sell, in their world, you would create in Desktop and publish to Server, so rather than export x150, your colleagues would simply log in to the secure portal and interact with what you made, no Excel required only Tableau Desktop and Server. Its a nice model, but you will pay.

                   

                  Happy to help more, if I can?!

                   

                  Cheers

                  Mark

                  1 of 1 people found this helpful
                  • 6. Re: Export All Charts to Excel
                    Mila T

                    Once again, thank you for the support. Could you tell me or explain in 2 sentences how to create scripts or where to put these commands? Should I install something else for these scripts? Haven't had a chance to work with scripts.

                    • 7. Re: Export All Charts to Excel
                      Mark Fraser

                      Open Notepad

                      Copy and paste everything above in italics (you would need to amend the site, login etc.)

                      Save as .bat < that is important, a .bat extension indicates to windows its a batch file

                       

                      Once you have a batch file, you can run it manually by double clicking, or right click, Open.

                      Or you can run it on a schedule in Windows -

                      http://www.thewindowsclub.com/how-to-schedule-batch-file-run-automatically-windows-7

                       

                      To be clear - you need Tableau Server + tabcmd for all the above. (as well as Notepad )

                       

                      Cheers

                      Mark

                      • 8. Re: Export All Charts to Excel
                        Mila T

                        So, I can't use this as I have only Tableau Desktop?

                        • 9. Re: Export All Charts to Excel
                          Mark Fraser

                          So, I can't use this as I have only Tableau Desktop?

                          No, sorry... as mentioned previously it requires Tableau Server.

                           

                          You can automate the export to Excel via Desktop using something like autolt, but its not Tableau supported.

                          >> Re: Automation of routine activities

                          and

                          Automate pdf generation using Tableau Desktop

                          • 10. Re: Export All Charts to Excel
                            Mila T

                            Thanks Mark, I appreciate your help regarding this matter.

                            • 11. Re: Export All Charts to Excel
                              Mark Fraser

                              You're very welcome, happy I could help.

                              Apologies I'm sure its not the answer you were looking for.

                               

                              You can download a 2 week free trial of Server - just make sure to have someone technical who can help you set it up!!

                               

                              Please could you mark one of my answer's as correct to close the thread?

                              Its useful if others stumble on this thread (as I'm sure they will, this comes up a lot!)

                               

                              Finally have a look in the ideas section - by voting you can influence Tableau

                              Here is one >> https://community.tableau.com/ideas/1694

                               

                              And if there is anything else, please feel free to use the forums, welcome!

                               

                              Cheers

                              Mark

                              3 of 3 people found this helpful