Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Macro Help

stevenlsj789
8 - Asteroid

Hello- I was able to use the RegEx to extract the first N words in a field with help from this forum yesterday. Today I am just trying to make this a Macro so I can reuse that later for my team. However my struggle is when I save the macro (in zip folder attached below) and later create a new workflow using different input file that my macro won't work. (I.e. the configuration for my marco will only include the fields in my original files). Can someone please help me with this? This is my first time making a Marco. Thank you so much! 

4 REPLIES 4
lmorrell
11 - Bolide

Hi @stevenlsj789 

 

Workflow zip is attached

 

Macro Help.png

 

Turning a macro from a static macro to something more dynamic can always be tricky - and lots of people have their own ways of dealing with it. However, one way to make the Macro more usable by a team member is to select "Show Field Map" in the Macro Input Tool so that we can map the fields within the Macro Configuration window. This will require EVERY field in your example dataset originally entered in the Macro Input Tool to be mapped to the Incoming datastream. However, if we only have a single column within the example, then processing will occur to only the mapped columns and leave the unmapped columns untouched - allowing the calculation to get appended as a new column. The result of doing this is as below:

 

Macro Help 2.png

 

Additionally, I made some minor tweaks to the macro so that the User Input number updated in the RegEx formula and that the macro functioned as intended. 

 

Macro Help 3.png

 

Hope this helps! 

stevenlsj789
8 - Asteroid

@lmorrell  

 

Thanks so much! This is super helpful. I was trying to open the workflow zip and see the changes you made. But had an error saying 'Alteryx does not support using an earlier version of Alteryx to open a workflow created with a newer version. For best results, download the latest version of Alteryx.' 

 

My enterprise account hasn't updated alteryx to the latest version yet. is there another way to share ? Sorry for the inconvenience, but I have version 2018.3.5. 

lmorrell
11 - Bolide

Hi @stevenlsj789 

 

Change version number.png

 

Happy to hear it's of help! If you open the Alteryx files in Notepad or Notepad++, you can change the version of the .yx* file by manually changing the version number and saving over the XML. This can be done to the files extracted from the same location as the .yxzp was opened from to preserve relative pathing - otherwise I have attached the files with this change made to them but you will need to ensure the Macro is in your mapped Macros folder prior to opening the workflow.

 

Let me know if you can get the files to open!  

stevenlsj789
8 - Asteroid

It worked. Thanks so much! 

Labels