program DateEnc;
uses PXEngine, WinCrt;

var   PxErr: Integer;
      Date: Longint;
      Month, Day, Year: Integer;

procedure PX(Code : integer);
begin
  writeln(PXErrMsg(Code));
end;

begin
  Month := 9;  Day := 13;  Year := 1989;
  PX(PXWinInit('MyApp', pxShared));

  (* Encode a date *)
  PxErr := PXDateEncode(Month, Day, Year, Date);
  if PxErr <> PxSuccess then
    Writeln(PxErrMsg(PxErr));

  PX(PXExit);
end.
