I am trying to run following lua code with DoFile() in NLua :
import('TestStack.White');
src=luanet.import_type('TestStack.White.UIItems.Finders.SearchCriteria')
application=Application.Launch('C:\\windows\\system32\\calc.exe')
win = application:GetWindow("Calculator");
win:WaitWhileBusy();
btnOne=win:Get(src.ByText("1")) <<---Exception here
btnOne:Click();
win:WaitWhileBusy();
I get following exception while executing this : {Late bound operations cannot be performed on types or methods for which ContainsGenericParameters is true.}
Equaivalent .net code which works fine is :
Application application = Application.Launch(@"C:\windows\system32\calc.exe");
Window window = application.GetWindow("Calculator");
window.WaitWhileBusy();
var btnOne = window.Get(SearchCriteria.ByText("1"));
btnOne.Click();
window.WaitWhileBusy();
Please help getting rid of this exception.
Additionally, I would also like to know " Is there a way to load a dll using lua , not already loaded in my .net application?"