I am currently working on a CDF in which users can change parameters of a 3D surface with Manipulate[]. Once the user is satisfied with the choice of parameters, I would like to offer an option to export and download the surface in the .stl format (for 3D printing). In a regular Mathematica notebook I can do this with the Export[] command, but I am not sure how to achieve this from within a CDF web player simulation? Is there a way to prompt a file download after, say, a Manipulate[]-created button has been pressed?
1 Answer
I think the only way to get such information out of a CDF document is to use the CopyToClipboard
function on a list and then paste into a text file (followed by maybe a bit of editing or post-processing). And I certainly hope this approach isn't taken away. I'd have to totally give up on CDF's if that were to happen.
APIFunction
to deploy an API that takes a set of parameters and generates the corresponding .stl file. You can link to it in your CDF withHyperlink
. $\endgroup$