The error message is exactly right. When you have a host object, you can't access it by the name of the local variable that holds it in your method (how would that even work? how would ScriptEngine
learn that name?).
Instead, you can access the host object directly, almost as if you were writing a member method of that type (but not quite, you can't use this
or access non-public members).
This means that you should write just:
session.Execute("destination")
BTW, according to .Net naming guidelines, names of public properties should start with upper case letter (e.g. Destination
).