TpaxScripter Demo. Hello.


//---------------------------------------------------------------------------

#include 
#pragma hdrstop

#include "Unit1.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma link "PaxScripter"
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
        : TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button1Click(TObject *Sender)
{
  PaxScripter1->Run(rmRun, "", 0);
}
//---------------------------------------------------------------------------
void __fastcall TForm1::PaxScripter1AssignScript(TPaxScripter *Sender)
{
  Sender->RegisterObject("Form1", Form1, -1);
  Sender->AddModule("main", paxBasic);
  Sender->AddCode("main", "print Form1.Caption");
}
//---------------------------------------------------------------------------


Copyright © 1999-2006 VIRT Laboratory. All rights reserved.