*--------------------------------------------------------------------------------------------------------------------------------------------------------
* (EN) AUTOGENERATED - ATTENTION!! - NOT INTENDED FOR EXECUTION!! USE ONLY FOR MERGING CHANGES AND STORING WITH SCM TOOLS!!
*--------------------------------------------------------------------------------------------------------------------------------------------------------
*< FOXBIN2PRG: Version="1.21" SourceFile="roagest.mnx" CPID="1252" /> (Solo para binarios VFP 9 / Only for VFP 9 binaries)
*
*<MenuType>1</MenuType>
*<MenuLocation>REPLACE</MenuLocation>

*<MenuCode>
DEFINE MENU _msysmenu BAR
DEFINE PAD _000000001 OF _msysmenu PROMPT "\<Utile" COLOR SCHEME 3 ;
	NEGOTIATE LEFT, NONE ;
	KEY ALT+U, "ALT+U" ;
	MESSAGE 'Instrumente utile: calculator, calendar, bloc-notes; iesirea din program.'

ON PAD _000000001 OF _msysmenu ACTIVATE POPUP Utile

	*----------------------------------
	DEFINE POPUP Utile MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 1 OF Utile PROMPT "\<Calculator" ;
		MESSAGE 'Deschide un calculator.'
	ON SELECTION BAR 1 OF Utile DO BAR_1_OF_Utile_FB2P

	DEFINE BAR 2 OF Utile PROMPT "\<Notepad" ;
		MESSAGE 'Deschide un carnetel.'
	ON SELECTION BAR 2 OF Utile DO BAR_2_OF_Utile_FB2P

	DEFINE BAR 3 OF Utile PROMPT "\-"
	ON BAR 3 OF Utile ACTIVATE POPUP _5ow12rytx

		*----------------------------------
		DEFINE POPUP _5ow12rytx MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 4 OF Utile PROMPT "Schimbare tip raport clasic/modern" ;
		MESSAGE 'Previzualizare rapoarte tip clasic sau modern'
	ON SELECTION BAR 4 OF Utile DO BAR_4_OF_Utile_FB2P

	DEFINE BAR 5 OF Utile PROMPT "\-"
	ON BAR 5 OF Utile ACTIVATE POPUP _s9r16veuj

		*----------------------------------
		DEFINE POPUP _s9r16veuj MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 6 OF Utile PROMPT "\<Iesire" ;
		KEY F2, "F2" ;
		MESSAGE 'Iesire din program.'
	ON SELECTION BAR 6 OF Utile DO BAR_6_OF_Utile_FB2P

DEFINE PAD _000000002 OF _msysmenu PROMPT "\<Editare" COLOR SCHEME 3 ;
	KEY ALT+E, "" ;
	MESSAGE 'Comenzi de editare.'

ON PAD _000000002 OF _msysmenu ACTIVATE POPUP Editare

	*----------------------------------
	DEFINE POPUP Editare MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR _med_undo OF Editare PROMPT "\<Anuleaza" ;
		KEY CTRL+Z, "Ctrl+Z" ;
		MESSAGE 'Anuleaza ultima comanda de editare.'

	DEFINE BAR _med_redo OF Editare PROMPT "\<Refa" ;
		KEY CTRL+R, "Ctrl+R" ;
		MESSAGE 'Repeta ultima comanda anulata.'

	DEFINE BAR _med_sp100 OF Editare PROMPT "\-"

	DEFINE BAR _med_cut OF Editare PROMPT "\<Taie si retine" ;
		KEY CTRL+X, "Ctrl+X" ;
		MESSAGE 'Copiaza in memorie textul selectat si apoi il sterge din ecran.'

	DEFINE BAR _med_copy OF Editare PROMPT "\<Copiaza" ;
		KEY CTRL+C, "Ctrl+C" ;
		MESSAGE 'Copiaza in memorie textul  selectat.'

	DEFINE BAR _med_paste OF Editare PROMPT "Re\<da" ;
		KEY CTRL+V, "Ctrl+V" ;
		MESSAGE 'Reda din memorie textul retinut cu comanda <Copiaza>.'

DEFINE PAD _000000003 OF _msysmenu PROMPT "\<Actualizari" COLOR SCHEME 3 ;
	SKIP FOR m.nivel>1 or luna_inchisa

ON PAD _000000003 OF _msysmenu ACTIVATE POPUP Actualizar

	*----------------------------------
	DEFINE POPUP Actualizar MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 1 OF Actualizar PROMPT "Initializare"
	ON BAR 1 OF Actualizar ACTIVATE POPUP Initializa

		*----------------------------------
		DEFINE POPUP Initializa MARGIN RELATIVE SHADOW COLOR SCHEME 4
		DEFINE BAR 1 OF Initializa PROMPT "Note contabile"
		ON SELECTION BAR 1 OF Initializa DO BAR_1_OF_Initializa_FB2P

	DEFINE BAR 2 OF Actualizar PROMPT "\-"
	ON BAR 2 OF Actualizar ACTIVATE POPUP _2z00kpm7w

		*----------------------------------
		DEFINE POPUP _2z00kpm7w MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 3 OF Actualizar PROMPT "Scriere nota din backup"
	ON SELECTION BAR 3 OF Actualizar DO BAR_3_OF_Actualizar_FB2P

	DEFINE BAR 4 OF Actualizar PROMPT "\-"
	ON BAR 4 OF Actualizar ACTIVATE POPUP _3en0pj4w2

		*----------------------------------
		DEFINE POPUP _3en0pj4w2 MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 5 OF Actualizar PROMPT "Actualizare stoc 24% 07/2010" ;
		SKIP FOR m.gnAn*12+m.gnLuna <> 2010*12+7
	ON BAR 5 OF Actualizar ACTIVATE POPUP _2z00lr4sl

		*----------------------------------
		DEFINE POPUP _2z00lr4sl MARGIN RELATIVE SHADOW COLOR SCHEME 4
		DEFINE BAR 1 OF _2z00lr4sl PROMPT "Actualizare stocuri cu pastrarea pretului de vanzare"
		ON SELECTION BAR 1 OF _2z00lr4sl do actualizare_stoc_072010 with 1 in actualizari.prg

		DEFINE BAR 2 OF _2z00lr4sl PROMPT "\-"
		ON BAR 2 OF _2z00lr4sl ACTIVATE POPUP _2z00lsxgj

			*----------------------------------
			DEFINE POPUP _2z00lsxgj MARGIN RELATIVE SHADOW COLOR SCHEME 4
		DEFINE BAR 3 OF _2z00lr4sl PROMPT "Actualizare stocuri cu cresterea pretului de vanzare"
		ON SELECTION BAR 3 OF _2z00lr4sl do actualizare_stoc_072010 with 0 in actualizari.prg

DEFINE PAD _000000004 OF _msysmenu PROMPT "A\<jutor" COLOR SCHEME 3 ;
	KEY ALT+J, "ALT+J" ;
	MESSAGE 'Instructiuni de utilizare, informatii despre acest program.'

ON PAD _000000004 OF _msysmenu ACTIVATE POPUP Ajutor

	*----------------------------------
	DEFINE POPUP Ajutor MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 1 OF Ajutor PROMPT "\<Instructiuni de utilizare"
	ON SELECTION BAR 1 OF Ajutor DO BAR_1_OF_Ajutor_FB2P

	DEFINE BAR 2 OF Ajutor PROMPT "\-"
	ON BAR 2 OF Ajutor ACTIVATE POPUP _1ts0rxko1

		*----------------------------------
		DEFINE POPUP _1ts0rxko1 MARGIN RELATIVE SHADOW COLOR SCHEME 4
	DEFINE BAR 3 OF Ajutor PROMPT "\<Jurnal modificari"
	ON SELECTION BAR 3 OF Ajutor DO BAR_3_OF_Ajutor_FB2P

	DEFINE BAR 4 OF Ajutor PROMPT "\<Despre program..." ;
		MESSAGE 'Informatii despre program'
	ON SELECTION BAR 4 OF Ajutor DO BAR_4_OF_Ajutor_FB2P
ON SELECTION MENU _msysmenu *:Locale=Yes

*</MenuCode>

*<Procedures>
PROCEDURE BAR_1_OF_Utile_FB2P
	DO apeleaza_calc IN oproceduri_comune.prg
ENDPROC && BAR_1_OF_Utile_FB2P

PROCEDURE BAR_2_OF_Utile_FB2P
	DO apeleaza_notepad IN oproceduri_comune.prg
ENDPROC && BAR_2_OF_Utile_FB2P

PROCEDURE BAR_4_OF_Utile_FB2P
	**OVARIABILE_GLOBALE.PRG
	
	*** Citesc setarea pentru ReportBehaviour
	IF TYPE('gnReportBehaviour') = 'U'
		PUBLIC gnReportBehaviour 
		gnReportBehaviour = 90
	ENDIF 
	
	LOCAL lcReportBehaviour
	lcReportBehaviour = NVL(getini(m.gcGeneralIniFile,'report','reportbehaviour'), '')
	IF EMPTY(m.lcReportBehaviour)
		setini(m.gcGeneralIniFile,'report','reportbehaviour', '90')
		gnReportBehaviour = 90
	ELSE
		gnReportBehaviour = VAL(m.lcReportBehaviour)
	ENDIF 
	IF !INLIST(gnReportBehaviour, 80, 90)
	     setini(m.gcGeneralIniFile,'report','reportbehaviour', '90')
		 gnReportBehaviour = 90
	ENDIF  
	
	lnReportBehaviourNew = IIF(gnReportBehaviour = 90, 80, 90)
	
	IF AMESSAGEBOX('Rapoarte tip ' + IIF(m.gnReportBehaviour=90, 'modern', 'clasic') + '. Doriti sa schimbati in tip ' + IIF(m.lnReportBehaviourNew=90, 'modern', 'clasic') + '?',4+32,_screen.Caption) = 6
		setini(m.gcGeneralIniFile,'report','reportbehaviour', ALLTRIM(STR(m.lnReportBehaviourNew)))
		gnReportBehaviour = m.lnReportBehaviourNew
	ENDIF 
ENDPROC && BAR_4_OF_Utile_FB2P

PROCEDURE BAR_6_OF_Utile_FB2P
	ies=.t.
	
	QUIT 
	
ENDPROC && BAR_6_OF_Utile_FB2P

PROCEDURE BAR_1_OF_Initializa_FB2P
	gcAcces = "1;2;3;4;"
	DO configurare_note IN omeniu_initializari.prg
ENDPROC && BAR_1_OF_Initializa_FB2P

PROCEDURE BAR_3_OF_Actualizar_FB2P
	gcAcces = "1;2;3;4;"
	do oscrie_in_fisiere.prg with 0, .F., .T., .F., .T.
ENDPROC && BAR_3_OF_Actualizar_FB2P

PROCEDURE BAR_1_OF_Ajutor_FB2P
	DO arata_manual IN oproceduri_comune.prg
ENDPROC && BAR_1_OF_Ajutor_FB2P

PROCEDURE BAR_3_OF_Ajutor_FB2P
	DO arata_modificari IN oproceduri_comune.prg
ENDPROC && BAR_3_OF_Ajutor_FB2P

PROCEDURE BAR_4_OF_Ajutor_FB2P
	DO arata_versiune IN oproceduri_comune.prg
ENDPROC && BAR_4_OF_Ajutor_FB2P

*</Procedures>
