Antonio - Retomo lo del tree podes ayudarme cn esto?

Antonio - Retomo lo del tree podes ayudarme cn esto?

Postby goosfancito » Thu May 05, 2022 12:19 pm

hace un tiempo intente y no funcionó, vos me dijiste que haga de una forma pero tampoco funcionó.
te comento: tengo un array que genero asi (con una tupla incluida):
Code: Select all  Expand view
   AAdd( ::aTree, { oQry:FieldGet( "c7" ) + "     " + ::cCargo, ;
                       { ;
                         "nId" => oQry:FieldGet( "c4" ), ;
                         "nIdPadre" => oQry:FieldGet( "c5" ), ;
                         "dFecha" => oQry:FieldGet( "c7" ), ;
                         "nHitem" => 0 ;
                       } } )
 


Luego necesito recorrer ese array para buscar un determinado valor que viene desde una tabla,
el valor existe y tambien existe en el array ::aTree pero el aScan me dice siempre que la posicion es cero
cuando deberia de ser mayor a cero:
Code: Select all  Expand view
        nPosicion := AScan( ::aTree, { | xCelda | xCelda[ 2 ][ "nId" ] == oQry:FieldGet( "c5" ) } )


En cambio si me recorro el array con un FOR NEXT o FOR EACH el valor existe.
FWH 21.02
Harbour 3.2.0dev (r2104281802)
Copyright (c) 1999-2021, https://harbour.github.io/
User avatar
goosfancito
 
Posts: 1954
Joined: Fri Oct 07, 2005 7:08 pm

Re: Antonio - Retomo lo del tree podes ayudarme cn esto?

Postby Antonio Linares » Fri May 06, 2022 8:26 am

regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41314
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain


Return to FiveWin para Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 72 guests