FastScrip - CallMethod
Hi.
When i put the AddMethod for fastscript in CB2009, ocurr the error:
[BCC32 Error] Main.cpp(26): E2285 Could not find a match for 'TfsScript::AddMethod(const char *,Variant (_fastcall * (_closure )(TObject *,TMetaClass *,const AnsiString,Variant &))(TObject *,TMetaClass *,const AnsiString,Variant &))'.
In CB5 and Delphi2009 this error not ocurr.
Anyone know how to resolve this, i tried a lot of things, but nothing functioned.
The code is very simple:
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
fsScript1->AddMethod("procedure CPPFUNC(string:x) ",&(this)->Method);
}
//
Variant __fastcall TForm1::Method(System::TObject* Instance, TMetaClass* ClassType, const AnsiString MethodName, Variant &Params)
{
return NULL;
}
//
When i put the AddMethod for fastscript in CB2009, ocurr the error:
[BCC32 Error] Main.cpp(26): E2285 Could not find a match for 'TfsScript::AddMethod(const char *,Variant (_fastcall * (_closure )(TObject *,TMetaClass *,const AnsiString,Variant &))(TObject *,TMetaClass *,const AnsiString,Variant &))'.
In CB5 and Delphi2009 this error not ocurr.
Anyone know how to resolve this, i tried a lot of things, but nothing functioned.
The code is very simple:
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
fsScript1->AddMethod("procedure CPPFUNC(string:x) ",&(this)->Method);
}
//
Variant __fastcall TForm1::Method(System::TObject* Instance, TMetaClass* ClassType, const AnsiString MethodName, Variant &Params)
{
return NULL;
}
//