Yes.
The best way is to write C wrapper around your function to provide the lua interface and attach the required function as a lua extension module.
The other way is to use P/Invoke extension library for the LUA
LuaForge: Lua Invoke: Project Info
To get access to a lua extension module:
1) Put your extension module into the lua_ext subfolder of the Indicore SDK and Marketscope folder.
2) Add the following code to the prepare() function of your indicator:
Code:
package.cpath = package.cpath .. ";" .. core.app_path() .. "\\lua_ext\\?.dll"
require("yourmodule");
I'll prepare an example of using P/Invoke in a few days.