1 страниц (6 вхождений)
Can I make the Smath Studio as an engine at back? - Сообщения
Hi
Is it possible to pack the smath studio in my software as a calculation engine at background? transfer my parameter into the sheet? produce the pdf of result?
thanks a lot!
John
Is it possible to pack the smath studio in my software as a calculation engine at background? transfer my parameter into the sheet? produce the pdf of result?
thanks a lot!
John
I know it's possible to run Smath from the command line and save as a specific output. What I am not sure about is whether or not you can pass parameters into the sheet using -o.
If you look in the reference book under Program Operation -> Silent Mode and Command Line Options you will get more info.

If you look in the reference book under Program Operation -> Silent Mode and Command Line Options you will get more info.

Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
So I was able to do this in a couple steps.
I put my inputs into a file called "input.txt". Then I created a .sm called "calc.sm" that read input from the input.txt file and performed a calculation.
The command line looked like this:

I have attached the .txt, .sm and .pdf files as well.
calc.pdf (21 КиБ) скачан 162 раз(а).
calc.sm (3 КиБ) скачан 145 раз(а).
input.txt (8 Б) скачан 139 раз(а).
I put my inputs into a file called "input.txt". Then I created a .sm called "calc.sm" that read input from the input.txt file and performed a calculation.
The command line looked like this:

I have attached the .txt, .sm and .pdf files as well.
calc.pdf (21 КиБ) скачан 162 раз(а).
calc.sm (3 КиБ) скачан 145 раз(а).
input.txt (8 Б) скачан 139 раз(а).
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
Perhaps improving on this concept a bit. I've added some commands to point the current working directory to the document directory. This way you can save the input.txt and calc.sm in the same folder. That way you could call:
SmathStudio_Desktop.exe -silent pathtosmfile -e pdf
and as long as the input file is in the same folder you don't have to point to the absolute path of the file. This makes it more portable.

calc.sm (3 КиБ) скачан 134 раз(а).
SmathStudio_Desktop.exe -silent pathtosmfile -e pdf
and as long as the input file is in the same folder you don't have to point to the absolute path of the file. This makes it more portable.

calc.sm (3 КиБ) скачан 134 раз(а).
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
WroteHi
Is it possible to pack the smath studio in my software as a calculation engine at background? transfer my parameter into the sheet? produce the pdf of result?
thanks a lot!
John
Re-reading this, yes it is possible, however, if your software is intended to be distributed, you must be careful how you package this as to not violate the license agreement. Only unmodified installer may be redistributed.
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
1 страниц (6 вхождений)
-
Новые сообщения
-
Нет новых сообщений