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.

Copying Section from file to Multiple Excel Files

RaviPM10
7 - Meteor

I have a folder containing 10 Excel files. From the master file’s "Input" sheet, I need to copy the "Super Category Override" & Fixed Income Characteristics section — which contains predefined category-level adjustments used for data standardization — and paste it into the "Input" sheet of the other 9 files, but only if that section exists in them. The formatting must be preserved during the process.

Looking for guidance on how to automate this in Alteryx

1 REPLY 1
jrlindem
11 - Bolide

A little hard to conceptualize this without the rest of the context, but here’s an attempt at a high level…

 

Master File:

  • Grab the correct data (using first row contains data) and then Filtering on [F1] where it equals “Super Category Override” or “Fixed Income Characteristics”
  • Then you can use a directory input tool to grab the 10 other files meta data (path and filenames) so you can use those in formulas to place the data from Master into those other files dynamically
    • Example:  [path] + [filename] + “|||” + [SheetName] + “!A1:Z99”
  • You can either explicitly call out the 10 outputs by duplicating the Master data (if it’s the same) or you can build a Macro to write to each of the 10 files, one at a time (looping behavior).

 

Regarding the “if the section exists”.  I assume you mean if the section exists in one or many of the ten destination files?  When you bring those in, you could check for cells that contain text to confirm whether or not the file needs the data pasted in…  Use that insight when configuring how the data flows into the Macro our Output tools (from above).

 

As for formatting, I’m not sure if you mean color or schema.  I think either of those can be handled by virtue of having that pre-set in your ten destination files, which you could copy/paste using BLOB tools.

 

Orchestration and assurance that things happen in the right sequence are accomplished through Block-Until-Done or Control-Containers.

 

 

Okay, okay, but that didn’t really provide you with a absolute solution…  But I hope that this gives you a general framework for how you can break this ask down into pieces and start to build something out that follows the above “plan” of attack (or hopefully something along those lines.).

 

What you’re asking, though, is certainly accomplishable.  I trust that gives you at least some assurance to push on and solve this interesting challenge!

 

Cheers, -Jay

Labels
Top Solution Authors