Incompatible types
I'm evaluating FastScript 1.7 on BCB 6 and am falling at the first hurdle. I get an error compiling the following script. The fsScript1 error message is "Incompatible types: 'class String', 'String' at 1:21"
Any help gratefully received
--
Antony
void __fastcall TForm1::Button1Click(TObject *Sender)
{
fsScript1->Clear();
fsScript1->Lines->Text = "{ ShowMsg(\"Hi there\"); }";
fsScript1->AddMethod("void ShowMsg(s:String)", CallMethod);
fsScript1->Parent = fsGlobalUnit();
fsScript1->SyntaxType = "C++Script";
if(!fsScript1->Compile())
 ShowMessage(fsScript1->ErrorMsg + " at " + fsScript1->ErrorPos);
else
 fsScript1->Execute();
}
One peculiarity: If I click Button1 a second time it all works fine!Any help gratefully received
--
Antony
Comments