Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

sorting Ecel tabs in Alteryx designer

StephenT
8 - Asteroid

Hi all,

Is there a way in Alteryx designer to sort Excel tabs ? I have an EXcel workbook that will by End of Year contain upto to 50-odd tabs and am looking for a way to have nee tabs (created weekly) appear at he far left-of the tabs already created (per screen shot below)

 

2022-11-10_7-58-35.png

 

8 REPLIES 8
gautiergodard
13 - Pulsar

@StephenTOne way to easily do this is by pre-pending a number to each one of your tab names.

 

i.e "1. LoA-2022-11-09" 

 

You can do this dynamically in the workflow to ensure the left-most tab is always labeled with a "1"

StephenT
8 - Asteroid

thansk @gautiergodard 
So the "1." at the front of the tab name will automatically insert it at the far left ?

gautiergodard
13 - Pulsar

@StephenT Correct, Alteryx will output the tab sequentially based on the number. 

 

Kindly accept this solution if it provided a solution to your question.

gautiergodard
13 - Pulsar

@StephenT did this work? If so please accept this solution to make it easier for others to find an answer ! 

StephenT
8 - Asteroid

Hoi @gautiergodard 
I ran a live data run today, and unfortunately the tabs prefixed with a number are being added to the very far-right, not the far left as desired.

deepaprash
8 - Asteroid

This used to work but does not work anymore. When you are writing data into each of the tabs, the data that is written first becomes the first tab rather than the one with the right numerical sequence. Using Control containers does not make it work either as I keep getting Could not write to file as its being used by another process error.

 

So I wrote to a temp location and then use vbs to write to wherever I need it to go. Such a round about way of doing it. I wish there was something easier.

jrlindem
12 - Quasar

@deepaprash  I'm not sure why the control container method isn't working for you?  One container per tab, written in the exact order that you want them should take care of the need and not move on until the tab is written...

 

@StephenT the way that I combat this, assuming you know how many tabs there will be and what they will be named, is to use a template with those tabs already in pre-existence.  You can then bring that template in using BLOB or Run Command to copy/paste the template and then load your data to the respective tabs from the workflow.  You'll still need to sequence the writing using control containers or block-until-done tools, but the effect should be the same.

 

Reach out if you need more specific guidance, -Jay

dreldrel
8 - Asteroid

You can use a union tool to combine your tabs and sort them before output. This should make sure the order is correct on your excel sheet

Labels
Top Solution Authors