Effacer les filtres
Effacer les filtres

Publishing a script that displays and example input from the expression window of the publisher?

2 vues (au cours des 30 derniers jours)
I'm working on a script that calculates the shipping cost of a package based on the weight of the package (as entered by the user in an input prompt). I want to publish as a PDF that calculates the cost at a weight that I enter in the expression window of the publishing editor, but no matter what format I use, the script doesn't utilize the input. How can I get the script to run using an example value for the package weight without removing the "input" prompt from the code?
  1 commentaire
Matt Rulli
Matt Rulli le 8 Avr 2019
weight = input(' Enter package weight [lbs]: ');
I want to keep this in my code, but I want it to display a computed value for a weight I enter in the expression window of the publisher. How do I bypass this portion of the code so my published PDF will display a price for an arbitrary weight entered in the expression window?

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Energy Production dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by