oFrPrn:SetMasterDetail("relven5a", "relven5c", {||relven5a->pedido})
oFrPrn:SetResyncPair( "relven5a", "relven5c" )
LOCAL hData := { "customerno" => 1,;
"customername" =>2,;
"city" =>3 }
:SetUserDataSet( "Customers", "CustomerNo;CustomerName;City", ;
{ || nAt := 1 },;
{ || nAt++ },;
{ || nAt-- },;
{ || nAt > LEN( aData ) },;
{ |cFld| nCol := hGet( hData, LOWER( cFld ) ), aData[ nAt, nCol ] } )
bResync := { |n| "Invoices"->( dbSeek( aData[ n, 1 ] ) ), oFrh:Resync( "invoices" ) }
:SetWorkArea( "Invoices", Select( "invoices" ) )
:SetUserDataSet( "Customers", "CustomerNo;CustomerName;City", ;
{ || nAt := 1, EVAL( bResync, nAt ) },;
{ || nAt++, EVAL( bResync, nAt ) },;
{ || nAt--, EVAL( bResync, nAt ) },;
{ || nAt > LEN( aData ) },;
{ |cFld| nCol := iif( hHasKey( hData, LOWER( cFld ) ), hGet( hData, LOWER( cFld ) ), 1 ),;
aData[ nAt, nCol ] } )
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: Google [Bot] and 89 guests