I understood I have aItems of 18 field and citemflds of 19
How I can make to set aItems to 19 fields ?
Otto wrote:'Silvio,
but before you can save a record you have to navigate to the recNo
METHOD GoTo( nRecNo )
or insert a new record.
METHOD Append()
Why don't you create a function, SAVE () and pass your data?
There you open your database again and save everything.
And then closes it.
For such a complicated task, this is more transparent.
And more secure. Commit, skip problems. More save in network enviroment.
Best regards,
Otto
AaDd(oBrowse:aArrayData,{ ".\bitmaps\servizio.png" ,;
"01" ,;
"servizio" ,;
1 ,;
9 ,;
9 ,;
,;
,;
,;
0 ,;
0 ,;
nInvoice ,;
.t. ,;
.t.,;
"",;
"",;
1 ,;
0,0} )
:bKeyDown := { |k| If( k == VK_DELETE, ( oBrowse:aAppend := nil, oBrowse:Delete(), 0 ), nil ) }
WITH OBJECT oBrowse:aCols[ 12]
:AddBitmap({"delete.bmp","broom.png"})
:nBtnBmp := 1
:lBmpStretch := .F.
:lBmpTransparent := .T.
:nwidth := 30
:nEditType := EDIT_BUTTON
:bEditBlock := { || oBrowse:Delete() }
:nHeadBmpNo := 2
:cHeader := ""
END
if ! Empty( oBrowse:aDeleted )
AEval( oBrowse:aDeleted, { |a| a[ 18 ] := -a[ 18 ] } )
oRigheInvoice:SaveArrayToDBF( cItemFlds,oBrowse:aDeleted ) // save the delete records
endif
if ! Empty( oBrowse:aDeleted )
AEval( oBrowse:aDeleted, { |a| a[ 19 ] := -a[ 19 ] } )
oRigheInvoice:SaveArrayToDBF( cItemFlds,oBrowse:aDeleted ) // save the delete records
endif
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: No registered users and 52 guests