How to call CSScript from unmanaged C++ DLL?

77 views
Skip to first unread message

Dimm

unread,
Sep 17, 2014, 4:15:16 PM9/17/14
to cs-s...@googlegroups.com
Hello, 

I would like to use CSScript  by calling it from unmanaged C++ DLL to execute scripts instead of keep updating the C++ code.
I also need to pass some variables back and forth. 
Thanks in advance

Oleg Shilo

unread,
Sep 17, 2014, 9:37:39 PM9/17/14
to cs-s...@googlegroups.com
This task is outside of the CS-Script problem domain. And in fact it is a generic .NET problem. You will find plenty of info on how to call managed code from unmanaged host. Unfortunately usually it requires using COM. 

However you can diractly host the CLR in your unmanaged app and it means that you can run cs-scripts the same way you do from the managed apps. Have a look at this article: http://www.codeproject.com/Articles/9903/Calling-Managed-Code-from-Unmanaged-Code-and-vice. CodeProject has some other similar articles as well. 
 
Cheers,
Oleg

--
You received this message because you are subscribed to the Google Groups "CS-Script" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cs-script+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages