fbpx
Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: how a script is called by code

how a script is called by code 1 year 11 months ago #2044

  softdevo@tiscali.it's Avatar Topic Author softdevo@tiscali.it Offline Posts: 85
Hi to all,
Sorry I did not understand how a script is called by code, and how to
get return values..
Thank you

Please Log in or Create an account to join the conversation.

how a script is called by code 1 year 11 months ago #2046

  robert's Avatar robert Offline Posts: 994
Danilo,

After the installation of X# you should have a shortcut on your desktop that brings you the public documents folder on your machine where we have installed some examples.
In the XSharp Script examples inside this folder you will find example programs.

The XIDE subfolder in this examples folder shows step by step examples that Nikos demonstrated in Cologne.

Example 1 shows how to call a script and get its return value with EvaluateAsync()
Example 2 shows how to pass arguments in a "Globals" objects
Example 3 shows how to catch errors
Example 4 shows how to compile a script without executing
Example 5 shows how to catch runtime errors
Example 6 shows how to handle strongly typed return values
Example 7 shows how you can compile a script once and run it many times
Example 8 shows a script that return a System.Func object
Example 9 shows how to access a function in the app from a script
Example 10 shows a script that uses the Dynamic type and late bound calls.

Please have a look at these scripts and let us know which thing you do not understand/
Note: If you want to use the scripts then make sure that the distributable files are available in the current folder or in the path. See the file "c:\Program Files (x86)\XSharp\Redist\Redist.txt" for a list of these DLLs.

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

  • Page:
  • 1