Hello
Within HMG package ---> hmg.3.2 looking into folder \SAMPLES
compiled and if you do not use the IDE can compiled
directly with a Bat file from cmd (Dos) I normally do
Bat like this one -----> build.3.2.bat and put inside :
@ECHO OFF
call c:\hmg.3.2\build.bat main %*
1º main prg would my application ---> main.prg
ie as seal me inside the Bat but without extension example clientes.prg
output:
@ECHO OFF
call c:\hmg.3.2\build.bat clientes %*
in the main PRG always go
# include " hmg.ch "
Function Main
followed by a main window example Form_1
DEFINE WINDOW Form_1 ;
AT 0,0 ;
WIDTH 500 HEIGHT 450;
TITLE " Hello World" ;
BACKCOLOR { 211,218,236 } ;
MAIN NOMAXIMIZE
KEY ACTION ON ESCAPE ThisWindow.Release
@ 050 , 200 Label_1 LABEL VALUE ' Hello World' ;
WIDTH 300 HEIGHT 18 FONT "Arial" SIZE 9 BOLD ITALIC BACKCOLOR {211,218,236 }
END WINDOW
WINDOW CENTER Form_1
ACTIVATE WINDOW Form_1
Return
this would be the source code
Code: Select all
#include "hmg.ch"
Function Main
DEFINE WINDOW Form_1 ;
AT 0,0 ;
WIDTH 500 HEIGHT 450 ;
TITLE " Hello World" ;
BACKCOLOR { 211,218,236 } ;
MAIN NOMAXIMIZE
ON KEY ESCAPE ACTION ThisWindow.Release
@ 050, 200 LABEL Label_1 VALUE "Hello World" ;
WIDTH 300 HEIGHT 18 FONT "Arial" SIZE 12 BOLD ITALIC BACKCOLOR {211,218,236 }
@ 200,225 BUTTON Exit_Program ;
CAPTION 'Exit' ;
WIDTH 70 HEIGHT 63 ;
ACTION Form_1.Release
END WINDOW
CENTER WINDOW Form_1
ACTIVATE WINDOW Form_1
Return Nil
Regars, Salam
Mustafa