*       *********************************************************
*       *                                                         
*       * 14/01/2013              HFR.MPR               09:36:32  
*       *                                                         
*       *********************************************************
*       *                                                         
*       * Author's Name                                           
*       *                                                         
*       * Copyright (c) 2013 Company Name                         
*       * Address                                                 
*       * City,     Zip                                           
*       *                                                         
*       * Description:                                            
*       * This program was automatically generated by GENMENU.    
*       *                                                         
*       *********************************************************


*       *********************************************************
*       *                                                         
*       *                      Menu Definition                    
*       *                                                         
*       *********************************************************
*

SET SYSMENU TO

SET SYSMENU AUTOMATIC

DEFINE PAD _3ox0klfs8 OF _MSYSMENU PROMPT "\<1. เข้าพัก" COLOR SCHEME 3 ;
	SKIP FOR Wborder()
DEFINE PAD _3ox0klfs9 OF _MSYSMENU PROMPT "\<2. เครื่องมือ" COLOR SCHEME 3 ;
	SKIP FOR Wborder()
DEFINE PAD _3ox0klfsa OF _MSYSMENU PROMPT "\<3. ออกจากระบบ" COLOR SCHEME 3
ON PAD _3ox0klfs8 OF _MSYSMENU ACTIVATE POPUP _1qq1cd1wk
ON PAD _3ox0klfs9 OF _MSYSMENU ACTIVATE POPUP _25500opso
ON PAD _3ox0klfsa OF _MSYSMENU ACTIVATE POPUP newitem

DEFINE POPUP _1qq1cd1wk MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF _1qq1cd1wk PROMPT "1.\<1 เข้าพัก" ;
	SKIP FOR !fRmRoom
DEFINE BAR 2 OF _1qq1cd1wk PROMPT "1.\<2 ตัดให้ตัวแทน" ;
	SKIP FOR !fRmAgent4M
DEFINE BAR 3 OF _1qq1cd1wk PROMPT "1.\<3 ลูกหนี้เงินเชื่อ" ;
	SKIP FOR !FrmDebtRoom
DEFINE BAR 4 OF _1qq1cd1wk PROMPT "\-"
DEFINE BAR 5 OF _1qq1cd1wk PROMPT "1.\<4 ปิดรอบวัน" ;
	SKIP FOR !FrmRoomPost && .or. !Between(Left(Time(),2),'04','10')
DEFINE BAR 6 OF _1qq1cd1wk PROMPT "\-"
DEFINE BAR 7 OF _1qq1cd1wk PROMPT "1.\<5 รายงานปิดรอบฯ" ;
	SKIP FOR !FrmHoEod
DEFINE BAR 8 OF _1qq1cd1wk PROMPT "1.\<6 ปิดรอบแคชเชียร์" ;
	SKIP FOR !FrmHoOut && .or. Between(Left(Time(),2),'04','10')
DEFINE BAR 9 OF _1qq1cd1wk PROMPT "\-"
DEFINE BAR 10 OF _1qq1cd1wk PROMPT "1.\<7 ออกจากโปรแกรม"
ON SELECTION BAR 1 OF _1qq1cd1wk ;
	DO _3ox0klfsb ;
	IN LOCFILE("S:\CUSTOMER\_AMPHAN\HFR" ,"MPX;MPR|FXP;PRG" ,"Where is HFR?")
ON SELECTION BAR 2 OF _1qq1cd1wk Do \Pos\Security\Prog\UpProg With 'Agent4M.Prg'
ON BAR 3 OF _1qq1cd1wk ACTIVATE POPUP _3ox0kj1do
ON SELECTION BAR 5 OF _1qq1cd1wk Do AllPost In UtilHo2
ON SELECTION BAR 7 OF _1qq1cd1wk Do HoEod.Spr
ON SELECTION BAR 8 OF _1qq1cd1wk Do HoOutPlus In UtilHo2
ON SELECTION BAR 10 OF _1qq1cd1wk ;
	DO _3ox0klfsc ;
	IN LOCFILE("S:\CUSTOMER\_AMPHAN\HFR" ,"MPX;MPR|FXP;PRG" ,"Where is HFR?")

DEFINE POPUP _3ox0kj1do MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF _3ox0kj1do PROMPT "1.3.\<1 พิมพ์ใบวางบิล"
DEFINE BAR 2 OF _3ox0kj1do PROMPT "1.3.\<2 พิมพ์ใบวางบิลซ้ำ"
DEFINE BAR 3 OF _3ox0kj1do PROMPT "1.3.\<3 รับชำระหนี้"
ON SELECTION BAR 1 OF _3ox0kj1do Do Ho2Ar.Prg With 'SET'
ON SELECTION BAR 2 OF _3ox0kj1do Do Ho2ArDup In Ho2Ar.Prg
ON SELECTION BAR 3 OF _3ox0kj1do Do Ho2Ar.Prg With 'PAY'

DEFINE POPUP _25500opso MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF _25500opso PROMPT "2.\<1 เตรียมข้อมูลแบบด่วน" ;
	SKIP FOR !FrmHoEasyDT
DEFINE BAR 2 OF _25500opso PROMPT "2.\<2 ปรับเวอร์ชั่น" ;
	SKIP FOR !FrmChkDbf
DEFINE BAR 3 OF _25500opso PROMPT "2.\<3 ปรับแฟ้มดัชนี" ;
	SKIP FOR !FrmRoomIdex
DEFINE BAR 4 OF _25500opso PROMPT "2.\<4 พิมพ์ใบเข้าพักฯ"
DEFINE BAR 5 OF _25500opso PROMPT "2.\<5 พิมพ์ใบเสร็จซ้ำ" ;
	SKIP FOR !FrmHoPrnDup
DEFINE BAR 6 OF _25500opso PROMPT "2.\<6 สำรองข้อมูล"
DEFINE BAR 7 OF _25500opso PROMPT "2.\<7 หัวข้อพิเศษ"
DEFINE BAR 8 OF _25500opso PROMPT "2.\<8 ปรับระบบไฟ"
ON SELECTION BAR 1 OF _25500opso Do HoEasyDT.Spr
ON SELECTION BAR 2 OF _25500opso Do UpVerHoProg In UtilHo
ON SELECTION BAR 3 OF _25500opso ;
	DO _3ox0klfsd ;
	IN LOCFILE("S:\CUSTOMER\_AMPHAN\HFR" ,"MPX;MPR|FXP;PRG" ,"Where is HFR?")
ON SELECTION BAR 4 OF _25500opso Do PrnRegIn.Prg
ON SELECTION BAR 5 OF _25500opso Do HoPrnDup.spr
ON SELECTION BAR 6 OF _25500opso Do \Pos\Security\Prog\BdBackup.Spr
ON SELECTION BAR 7 OF _25500opso Do \Pos\Security\Prog\Sm_Spec.Prg
ON SELECTION BAR 8 OF _25500opso Do AmPhan.Prg

DEFINE POPUP newitem MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF newitem PROMPT "3.\<1 เปลี่ยนรหัสผู้ใช้" ;
	SKIP FOR Wborder()
DEFINE BAR 2 OF newitem PROMPT "3.\<2 ออกจากโปรแกรม"
ON SELECTION BAR 1 OF newitem Do HoChgUr.Prg
ON SELECTION BAR 2 OF newitem ;
	DO _3ox0klfse ;
	IN LOCFILE("S:\CUSTOMER\_AMPHAN\HFR" ,"MPX;MPR|FXP;PRG" ,"Where is HFR?")


*       *********************************************************
*       *                                                         
*       *                 Cleanup Code & Procedures               
*       *                                                         
*       *********************************************************
*







Procedure OpenFront
If !Used('RoomCode')
	Use RoomCode In 0 Share Noupdate Alias RoomCode Order Rmno
Endif
If !Used('Room')
	Use Room In 0 Share Noupdate Alias Room Order Tag1
Endif
If !Used('Guest')
	Use Guest In 0 Share noupdate Alias Guest Order Guestcode
Endif
Return





*       *********************************************************
*       *                                                         
*       * _3OX0KLFSB  ON SELECTION BAR 1 OF POPUP _1qq1cd1wk      
*       *                                                         
*       * Procedure Origin:                                       
*       *                                                         
*       * From Menu:  HFR.MPR,            Record:    5            
*       * Called By:  ON SELECTION BAR 1 OF POPUP _1qq1cd1wk      
*       * Prompt:     1.1 เข้าพัก                                 
*       * Snippet:    1                                           
*       *                                                         
*       *********************************************************
*
PROCEDURE _3ox0klfsb
mRoom4Flag ='D'
nPSysCalDay=1
Do Floorrun.Spr
Set Message To



*       *********************************************************
*       *                                                         
*       * _3OX0KLFSC  ON SELECTION BAR 10 OF POPUP _1qq1cd1wk     
*       *                                                         
*       * Procedure Origin:                                       
*       *                                                         
*       * From Menu:  HFR.MPR,            Record:   18            
*       * Called By:  ON SELECTION BAR 10 OF POPUP _1qq1cd1wk     
*       * Prompt:     1.7 ออกจากโปรแกรม                           
*       * Snippet:    2                                           
*       *                                                         
*       *********************************************************
*
PROCEDURE _3ox0klfsc
Do HoMenuOut In HoChgUr.Prg


*       *********************************************************
*       *                                                         
*       * _3OX0KLFSD  ON SELECTION BAR 3 OF POPUP _25500opso      
*       *                                                         
*       * Procedure Origin:                                       
*       *                                                         
*       * From Menu:  HFR.MPR,            Record:   23            
*       * Called By:  ON SELECTION BAR 3 OF POPUP _25500opso      
*       * Prompt:     2.3 ปรับแฟ้มดัชนี                           
*       * Snippet:    3                                           
*       *                                                         
*       *********************************************************
*
PROCEDURE _3ox0klfsd
m.alrtbott=2
m.nfShowBOT=1
Do Fox_Bott With 1,'ปรับปรุงแฟ้มดัชนีทั้งหมด','ไม่ PACK ข้อมูล','PACK ข้อมูลด้วย'
If m.alrtbott=1 .and. Between(m.alrtbott,1,2)
	Do \Pos\Security\Prog\AlIndex.Prg With '',.T.,Iif(m.nfShowBOT=2,.T.,.F.)
	Do ChkFleMas In UtilHo
	Do UpRmRunDex In \Pos\Security\Prog\HoProg.Prg
	Do CrHoDexSCU In \Pos\Security\Prog\HoInit.Prg
Endif



*       *********************************************************
*       *                                                         
*       * _3OX0KLFSE  ON SELECTION BAR 2 OF POPUP newitem         
*       *                                                         
*       * Procedure Origin:                                       
*       *                                                         
*       * From Menu:  HFR.MPR,            Record:   32            
*       * Called By:  ON SELECTION BAR 2 OF POPUP newitem         
*       * Prompt:     3.2 ออกจากโปรแกรม                           
*       * Snippet:    4                                           
*       *                                                         
*       *********************************************************
*
PROCEDURE _3ox0klfse
Do HoMenuOut In HoChgUr.Prg
