Alteryx Designer Desktop Discussions

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

Access to filename in macro workflow

jeffv
8 - Asteroid

Just thought maybe someone might have insight to something I need in a workflow...

 

Say I have a macro:

 

1: Macro input with file name

2: Filter

3: Summary

4: Table

5: Email

 

Is there access to the filename passed in to include in the email?  By access I mean can I include in email the name of the file passed to macro?

 

Thanks!

Jeff

 

11 REPLIES 11
BenMoss
ACE Emeritus
ACE Emeritus

Your right, there isn't too many resources or blogs about batch macro's or iterative macro's, but hopefully with some exposure to them you'll get a good level of knowledge about the individual usecases.

 

To my knowledge, only batch macro's work with control paramters, iterative macro's do not. But the definitions you give are fair.

 

In your case 'his case I just wanted to process a list of files '

 

You could interpret each file as a 'group' and therefor this is why a batch macro works.

 

You could achieve your desired route with just a standard macro, but you'd have to use the dynamic input tool instead and pass the filenames in through a standard macro input. The reason I didn't in your example was based on the starting point you gave us.

 

Ben

 

It would look something like the below:

 

Test.png

jeffv
8 - Asteroid

Thank you for your response...  I've been pondering much of today...

I must have been mistaken on iterative macros with your insight on the control parameter...  hopefully one day it will make sense to me.  I see how treating each file as a group allows the batch macro to work.

 

However, you expanded my vision with standard macro and using dynamic input tool a bit beyond me... which is good (but frustrating because I can't seem to play with it and figure it out).

 

Going down that path...  the driver stays essentially the same.  In the macro for your picture I change to use the macro input.  This gets the files passed into macro and passes them along to the dynamic input tool.  In playing with it (haven't used it before),  I see the first section call input data source template....  if I understand correctly I'm giving it an example (in my case) excel file and pointing it to a particular worksheet name that will provide it a format of what fields to expect etc. Right?

 

The next section: read a list of data sources...  in my use case of trying to read a worksheet and count how many rows (simplified for example) I'm not sure how I configure this?

 

The next section: modify sql query I assume is not used for my use case.  Right?

 

Thanks for your patience... just trying to make sense of it all.

 

Jeff

 

 

Labels