Scripting Language


#1

Hello,

May I know if there is an interface for a scripting language also available? One place where I feel it might be useful is in the following case:

Ex: Step-by-Step tutorial: Homework Session 1 (3D printer workshop)
In this while defining the “Heat flux boundary condition,” using the topology map: “to all surrounding surfaces of the assembly (except contacts and the surface where you applied the resistor boundary condition)” it might be difficult to keep track of the annotated surfaces previously. Through a script, we can quickly see and define it programmatically.


#2

Hey @eulerianial!

Thanks for the post. Unfortunately it’s not possible since scripting may lead to security problems…

-Ahmed (@ahmedhussain18)


#3

@ahmedhussain18 Thank Ahmed! Just in case you might plan to add it. This platform has already taken care of that, may be good to check. https://c9.io/ But yes, at-least for my work and learning not absolutely needed.


#4

There are 2 good solutions to the security problem for online scripting:
Javascript: Javascript provides a secure runtime environment, and you can expose your functionality by providing functions for Javascript. You can provide functions to interact with your environment in Javascript. Mozilla provides the Javascript engine that is used in Firefox as a library that you can integrate in your own applications. Bindings for various languages are available, e.g. http://search.cpan.org/~claesjac/JavaScript-1.16/lib/JavaScript.pm

For usability, I suggest to use Blockly: https://developers.google.com/blockly/
This provides an easy user-interface for the users to define their own code/scripts, and it automatically generates Javascript code, which you can then run in a Javascript engine on your server. Alternatively your users can code javascript directly.
Together this is a safe, easy and secure way to provide scripting on Websites.
Feel free to contact me if you need help with it.


#5

+1 for the scripting feature! Especially most simulation engineers need DOE and most of the time that will need scripting support.


#6

I have added this in to Vote-for-features Category. You can now vote it also.

Best,
Ahmed