*--------------------------------------------------------------------------------------------------------------------------------------------------------
* (EN) AUTOGENERATED - ATTENTION!! - NOT INTENDED FOR EXECUTION!! USE ONLY FOR MERGING CHANGES AND STORING WITH SCM TOOLS!!
*--------------------------------------------------------------------------------------------------------------------------------------------------------
*< FOXBIN2PRG: Version="1.21" SourceFile="valoare.scx" CPID="1252" /> (Solo para binarios VFP 9 / Only for VFP 9 binaries)
*
*
DEFINE CLASS dataenvironment AS dataenvironment 
 	*< CLASSDATA: Baseclass="dataenvironment" Timestamp="" Scale="" Uniqueid="" ClassIcon="1" />

	*<PropValue>
		Name = "Dataenvironment"
	*</PropValue>

ENDDEFINE

DEFINE CLASS ffergen12 AS ffergen OF "..\clase\ferestrebaza.vcx" 
 	*< CLASSDATA: Baseclass="form" Timestamp="" Scale="" Uniqueid="" />

	*-- OBJECTDATA items order determines ZOrder / El orden de los items OBJECTDATA determina el ZOrder 
	*< OBJECTDATA: ObjPath="Shape1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Text2" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Label1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Grid1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Grid1.Column1.Header1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Grid1.Column1.Text1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Grid1.Column2.Header1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Grid1.Column2.Text1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Grid1.Column3.Header1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Grid1.Column3.Text1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Label3" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Shape2" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Titlufrumos1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Cmdtermin1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="Urmator1" UniqueID="" Timestamp="" />
	*< OBJECTDATA: ObjPath="CMDRENUNT1" UniqueID="" Timestamp="" />

	*<PropValue>
		BorderStyle = 1
		DataSession = 1
		DoCreate = .T.
		Height = 273
		KeyPreview = .T.
		Name = "Ffergen12"
		Width = 452
	*</PropValue>

	ADD OBJECT 'CMDRENUNT1' AS cmdrenunt WITH ;
		Height = 27, ;
		Left = 388, ;
		Name = "CMDRENUNT1", ;
		Top = 3, ;
		Width = 30, ;
		ZOrderSet = 9, ;
		Imbuton1.Height = 27, ;
		Imbuton1.Name = "Imbuton1", ;
		Imbuton1.Width = 30, ;
		Command1.Name = "Command1"
		*< END OBJECT: ClassLib="..\clase\ferestrebaza.vcx" BaseClass="container" />

	ADD OBJECT 'Cmdtermin1' AS cmdtermin WITH ;
		Height = 24, ;
		Left = 12, ;
		Name = "Cmdtermin1", ;
		TabIndex = 2, ;
		Top = 240, ;
		Visible = .F., ;
		Width = 29, ;
		ZOrderSet = 8, ;
		Imbuton1.Height = 27, ;
		Imbuton1.Name = "Imbuton1", ;
		Imbuton1.Width = 30, ;
		Command1.Name = "Command1"
		*< END OBJECT: ClassLib="..\clase\ferestrebaza.vcx" BaseClass="container" />

	ADD OBJECT 'Grid1' AS grid WITH ;
		ColumnCount = 3, ;
		DeleteMark = .F., ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		Height = 189, ;
		Left = 11, ;
		Name = "Grid1", ;
		Panel = 1, ;
		RecordSource = "tmf", ;
		RowHeight = 19, ;
		TabIndex = 1, ;
		Top = 43, ;
		Width = 426, ;
		ZOrderSet = 4, ;
		Column1.BackColor = 255,255,255, ;
		Column1.ControlSource = "denumire", ;
		Column1.FontName = "Arial Narrow", ;
		Column1.FontSize = 10, ;
		Column1.Name = "Column1", ;
		Column1.ReadOnly = .T., ;
		Column1.Width = 173, ;
		Column2.BackColor = 255,255,255, ;
		Column2.ControlSource = "valini", ;
		Column2.FontName = "Arial Narrow", ;
		Column2.FontSize = 10, ;
		Column2.InputMask = (GET_MASK(14,gnZ)), ;
		Column2.Name = "Column2", ;
		Column2.ReadOnly = .T., ;
		Column2.Width = 108, ;
		Column3.BackColor = 232,255,255, ;
		Column3.ControlSource = "valtrans", ;
		Column3.FontName = "Arial Narrow", ;
		Column3.FontSize = 10, ;
		Column3.Format = "rk", ;
		Column3.InputMask = (GET_MASK(14,gnZ)), ;
		Column3.Name = "Column3", ;
		Column3.Width = 113
		*< END OBJECT: BaseClass="grid" />

	ADD OBJECT 'Grid1.Column1.Header1' AS header WITH ;
		Alignment = 2, ;
		Caption = "Denumire", ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		Name = "Header1"
		*< END OBJECT: BaseClass="header" />

	ADD OBJECT 'Grid1.Column1.Text1' AS textbox WITH ;
		BackColor = 255,255,255, ;
		BorderStyle = 0, ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		ForeColor = 0,0,0, ;
		Margin = 0, ;
		Name = "Text1", ;
		ReadOnly = .T.
		*< END OBJECT: BaseClass="textbox" />

	ADD OBJECT 'Grid1.Column2.Header1' AS header WITH ;
		Alignment = 2, ;
		Caption = "Valoarea initiala", ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		Name = "Header1"
		*< END OBJECT: BaseClass="header" />

	ADD OBJECT 'Grid1.Column2.Text1' AS textbox WITH ;
		BackColor = 255,255,255, ;
		BorderStyle = 0, ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		ForeColor = 0,0,0, ;
		Margin = 0, ;
		Name = "Text1", ;
		ReadOnly = .T.
		*< END OBJECT: BaseClass="textbox" />

	ADD OBJECT 'Grid1.Column3.Header1' AS header WITH ;
		Alignment = 2, ;
		Caption = "Valoarea retinuta", ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		Name = "Header1"
		*< END OBJECT: BaseClass="header" />

	ADD OBJECT 'Grid1.Column3.Text1' AS textbox WITH ;
		BackColor = 232,255,255, ;
		BorderStyle = 0, ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		ForeColor = 0,0,0, ;
		Margin = 0, ;
		Name = "Text1"
		*< END OBJECT: BaseClass="textbox" />

	ADD OBJECT 'Label1' AS label WITH ;
		AutoSize = .F., ;
		BackStyle = 0, ;
		Caption = "Introduceti valorile care se transforma in mijloc fix ", ;
		FontSize = 10, ;
		Height = 22, ;
		Left = 15, ;
		Name = "Label1", ;
		TabIndex = 4, ;
		Top = 16, ;
		Width = 287, ;
		WordWrap = .T., ;
		ZOrderSet = 3
		*< END OBJECT: BaseClass="label" />

	ADD OBJECT 'Label3' AS label WITH ;
		AutoSize = .T., ;
		BackStyle = 0, ;
		Caption = "Total valoare retinuta", ;
		Height = 17, ;
		Left = 184, ;
		Name = "Label3", ;
		TabIndex = 5, ;
		Top = 240, ;
		Width = 116, ;
		ZOrderSet = 5
		*< END OBJECT: BaseClass="label" />

	ADD OBJECT 'Shape1' AS shape WITH ;
		BackStyle = 0, ;
		Height = 229, ;
		Left = 4, ;
		Name = "Shape1", ;
		SpecialEffect = 0, ;
		Top = 38, ;
		Width = 443, ;
		ZOrderSet = 0
		*< END OBJECT: BaseClass="shape" />

	ADD OBJECT 'Shape2' AS shape WITH ;
		BackColor = 0,64,128, ;
		BorderStyle = 0, ;
		BorderWidth = 0, ;
		Height = 33, ;
		Left = -1, ;
		Name = "Shape2", ;
		Top = 0, ;
		Width = 385, ;
		ZOrderSet = 6
		*< END OBJECT: BaseClass="shape" />

	ADD OBJECT 'Text2' AS textbox WITH ;
		BackColor = 255,255,255, ;
		ControlSource = "total", ;
		DisabledBackColor = 255,255,255, ;
		FontName = "Arial Narrow", ;
		FontSize = 10, ;
		Format = "rk", ;
		Height = 23, ;
		InputMask = (GET_MASK(14,gnZ)), ;
		Left = 302, ;
		Name = "Text2", ;
		ReadOnly = .T., ;
		SpecialEffect = 2, ;
		TabIndex = 3, ;
		Top = 237, ;
		Width = 119, ;
		ZOrderSet = 2
		*< END OBJECT: BaseClass="textbox" />

	ADD OBJECT 'Titlufrumos1' AS titlufrumos WITH ;
		Caption = "Introduceti valoarea care se transforma in mijloc fix", ;
		Height = 37, ;
		Left = 4, ;
		Name = "Titlufrumos1", ;
		Top = 9, ;
		Width = 323, ;
		ZOrderSet = 7
		*< END OBJECT: ClassLib="..\..\comun\clase\baza.vcx" BaseClass="label" />

	ADD OBJECT 'Urmator1' AS urmator WITH ;
		Height = 27, ;
		Left = 420, ;
		Name = "Urmator1", ;
		Top = 3, ;
		Width = 30, ;
		Imbuton1.Height = 27, ;
		Imbuton1.Name = "Imbuton1", ;
		Imbuton1.Width = 30, ;
		Command1.Name = "Command1"
		*< END OBJECT: ClassLib="..\..\comun\clase\baza.vcx" BaseClass="container" />
	
	PROCEDURE Init
		PUBLIC total
		
	ENDPROC

	PROCEDURE KeyPress
		LPARAMETERS nKeyCode, nShiftAltCtrl
		*!*		IF nkeycode=13
		*!*			IF UPPER(this.ActiveControl.name)="GRID1"
		*!*				NODEFAULT 
		*!*				SELECT TMF
		*!*				SKIP
		*!*				THIS.GRID1.SetFocus
		*!*				
		*!*			ENDIF
		*!*		ENDIF 
	ENDPROC

	PROCEDURE Cmdtermin1.Command1.GotFocus
		thisform.text2.Refresh 
	ENDPROC

	PROCEDURE Grid1.AfterRowColChange
		LPARAMETERS nColIndex
		r=RECNO()
		SELECT tmf
		SUM valtrans TO total
		thisform.text2.Refresh 
		GO r
	ENDPROC

	PROCEDURE Grid1.BeforeRowColChange
		LPARAMETERS nColIndex
		
	ENDPROC

	PROCEDURE Grid1.Column3.Text1.KeyPress
		LPARAMETERS nKeyCode, nShiftAltCtrl
	ENDPROC

	PROCEDURE Grid1.Column3.Text1.Valid
		IF valtrans>valini
		DO mesaj WITH "Valoarea transformata este mai mare decat ",'valoarea initiala !'
		RETURN 0
		ENDIF 
	ENDPROC

	PROCEDURE Urmator1.Command1.Click
		BUTON=1
		THISFORM.release 
	ENDPROC

	PROCEDURE Urmator1.Command1.GotFocus
		thisform.text2.Refresh 
	ENDPROC

ENDDEFINE
