Print a string to the standard output as well as a file
function print2 import Modelica.Utilities.Streams.print; input String string = "" "String to be printed"; input String fileName = "" "File where to print (empty string is the terminal)" annotation( Dialog(__Dymola_saveSelector(filter = "Text files (*.txt)", caption = "Text file to store the output of print(..)"))); end print2;