FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour loading the data info from dbf
Posts: 7317
Joined: Thu Oct 18, 2012 07:17 PM
loading the data info from dbf
Posted: Wed Jun 23, 2021 10:24 AM
I load in the aItems array first a line that I need for the umbrella info, then I load the services in the same array aItems

Code (fw): Select all Collapse
aItems:=AddFirstRecord()
aItems := oRigheInvoice:DbfToArray( cItemFlds, { || FIELD->Invoice ==alltrim(nInvoice) } )


the problem is that
aItems := oRigheInvoice:DbfToArray( cItemFlds, { || FIELD->Invoice ==alltrim(nInvoice) } )

delete everything in aItems
how should i not delete what it finds in aItems?
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 7317
Joined: Thu Oct 18, 2012 07:17 PM
Re: loading the data info from dbf
Posted: Wed Jun 23, 2021 10:31 AM

Now I correct with

         aItems:=AddFirstRecord(...)
        aRighe:={}
         aRighe := oRigheInvoice:DbfToArray( cItemFlds, { || FIELD->Invoice ==alltrim(nInvoice) } )
     for n= 1 to len(arighe)
        aadd( aItems,aRighe[n])
     next

but is it correct to do it this way?

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com

Continue the discussion