เพิ่งจะมีเวลาว่างครับ ก็เลยมานั่งเขียน ตัวอย่างการเขียนโปรแกรมด้วย Pascal Script ที่อยู่ใน HOSxP ดัดแปลงมาจากที่นี่ครับ 
http://www.delphibasics.co.uk/Article.asp?Name=FirstPgmเป็น Script ที่มีปุ่มให้ผู้ใช้กดและจะแสดงข้อความ Hello World ครับ 
ตัว Pascal Script Interpreter ที่มากับ HOSxP จะเรียกใช้ Procedure Main ใน Script ครับ ดังนั้นทุก Script จึงต้องมี Procedure Main ครับ
// comment hello world script for hosxp
// ชื่อ Unit จะตั้งเป็นอะไรก็ได้ ลงท้ายด้วยเครื่องหมาย เซมิโคล่อน
Unit Script;  
 
// การประกาศตัวแปร ใช้คำว่า var  ตัวอย่างด้านล่างเป็นการประกาศตัวแปรชนิด TButton ,TLabel และ TForm โดยใช้ชื่อว่า Button1, Label1 และ Form1
var
  Button1 : TButton;
  Label1 : TLabel;
  Form1 : TForm;
 
Implementation
 
// กำหนด Procedure ชื่อ Button1Click สำหรับทำงานเมื่อมีการกดปุ่ม Button1
 
Procedure Button1Click(Sender : TObject);
begin
  Label1.caption := 'Hello World';
end;
 
Procedure Main;
 
begin
 
  Form1 := TForm.create(nil);
  Form1.Top := 100;
  Form1.Left := 200;
  Form1.Width := 400;
  Form1.Height := 400;
 
  Button1 := TButton.create(Form1);
  Button1.parent := Form1;
  Button1.left:=100;
  Button1.top:=50;
  Button1.caption:='Click me';
  Button1.OnClick := Button1Click;  // กำหนด Event เมื่อผู้ใช้เมาส์คลิกปุ่ม จะเรียกใช้งาน Procedure Button1Click ด้านบน
 
  Label1 := TLabel.create(Form1);
  Label1.parent := Form1;
  Label1.top:=55;
  Label1.left:=200;
  Label1.caption:='---';
 
  Form1.ShowModal;  // แสดง Form1 แบบ Modal Form
 
  Form1.Free;
end;
end.