Hi, I am trying to create an app to upload to our gallery which outputs data into a sheet of an excel file. The file has other sheets which display the data from alteryx in different ways.
I have got this working fine in designer on my pc however when I upload the app to the gallery and run it there the output is an excel file with just the data from alteryx (i.e. the data is being put into a blank excel file rather than the template I have created).
Is it possible to output to an excel template from the gallery?
Thanks,
Richard
Hi Richard! Here is my suggestion that worked for me: whatever template file you intend to output to, I would add an input tool to read that exact file to your workflow (it doesn't matter what sheet you read). Then you can add a Tool container, place the input tool in the container, and disable that container. When you upload to the gallery, be sure to have that file checked under the view workflow assets. I've included a sample workflow to show you that I'm outputting to sheet1 and sheet2 has a formula to display your text. This should fix your dilemma.
In case you're curious, here's my take on what is happening. When you just have the output tool and you check the box to package it up with the workflow, it doesn't actually send the excel file with the workflow to the server to store in the Mongo files. Alternatively, if you have an input (even if it's disabled) and package it up with workflow, then it does send the excel file with the workflow to the server to store in the Mongo files. Now that it's sending the file, your template should work just fine.
Let me know if you run into any problems!
you should be able to add the excel template file as an Asset which you can refer to as an output in the app.
Here's a knowledge base article on the matter:
Here's a relevent snippet from that article:
To include additional files, you need to enable Asset Management which can be found under Options ->User Settings-> Edit User Settings -> Advanced, check the box, Display Asset Management in Properties window. Once this is enabled, you will be able to include assets with your workflows.
Return to your workflow canvas and select the Input tool (or any tool that may require an asset or dependency, like Input/Output tools or the Run Command tool). In the Configuration Window, click theAssets icon then Add Files to browse to the additional files to include.
Thanks a lot to you both for your responses - I've got it working using the input data and disable method. I'll see if I can get it working the second way as well as it could be a bit tidier
This solution works fine on desktop; however, I'm still getting the same error on the gallery even if I push your sample app directly to our gallery. Error message is still
Is there a server setting causing this issue?
Hi rld2,
I have the same issue as you. Did you figure out a solution to solve the problem ?
Thanks !
Hello Patrick, I have what might be a similar situation, whereby I have an EXCEL output from a workflow that will be run from the Gallery. I have an EXCEL macro that I'd like to have included in that output, along with an EXCEL sheet that advises the user to run the macro (and that sheet is the one that I'd like to open when the EXCEL output is opened by the user if possible). Can I use the Tool Container and an input tool that pulls in the EXCEL file with the macro, and then have my other EXCEL output sheets be contained in the file that has the macro?
I also wanted the output file (a macro enabled Excel file) to include the macro module, which they could run once they download from the Gallery (I actually set the macro to auto-run when the file is opened).
I used the option described by @patrick_digan putting an Input Data tool inside a disabled tool container. That Input Data tool has connected to my same Excel.xlsm file that my actual Output Data tool was also writing to (with an 'Overwrite sheet (Drop)'). At first this did not work for me as the Gallery gave an error saying that it still could not find the output file, despite the file in the container clearly being shown as one of the assets in the workflow.
The key was to ensure that both assets (the Input file in the container, and the Output file) were uploaded to the same folder location when I saved the workflow to the Gallery. The simplest way to do this is to open the Workflow Dependencies (Options>Advanced Options>Workflow Dependencies) and then manually change the directory location of these files to match. Just click on the Edit button of the Output Data file and change it to match the Input Data file's directory location.