Hi all,
Example:I have a file ABCD.xlsx with a sheet named PropertiesCell A1 on the Properties sheet contains a name, e.g., XYZI want to save the file as XYZ.xlsx
Is there a formula or tool that can save the workbook using the dynamic value in Properties!A1?
Using the formula tool, you can follow the format of: \path\filename.xlsx|||sheetname
The trick is in the triple-pipes. But you can definitely do this with a "cell" value. If you need the A1 value from your input data, you can just use that in the final formula to create the output, but of course you can't reference something that's not already existing, so you'll have to put some though into how that Properties!A1 value comes into your workflow.
Here is the Output Path Logic :[Name] + ".xlsx|||" + [Name]+ "$A1:z"you can change the sheet name part second name part in the formula, and update the output tool config as per the attached workflow or screenshot.
Hi, @mdara
Because you are essentially renaming or copying an existing Excel file based on the value of cell A1 in a specific sheet, you may need to use the Run Command tool in Alteryx to achieve this requirement.
'@Rem @cd /d "' + FileGetDir([FileName]) + '" copy /y "' + FileGetFileName([FileName]) + '.xlsx" "' + IIF(IsEmpty([F1]), 'Null', [F1]) + '.xlsx" @pause'
Hi @flying008
thanks for your solution - however I encountered below error in the Run Cmd.bat.When I run the program the Cmd bat is created in the temp folder but that's just it. Also I don't have option Quote Output Fields - Never option in the Run command tool:
Can you attach the workflow? I'm guessing you have a minor syntax error and i'm also curious how many fields and rows you're sending to the final tool. It should just be one field and a distinct value (you can send multiple rows to the Run Command tool but is not typical). -Jay
You need save as cmd.bat to .csv in run command tool, not .yxdb ! please look for the option of above gif .