asort array but on row

Post Reply
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

asort array but on row

Post by Silvio.Falconi »

I wish order an array but on row sample

Image

I wish the numbers of each row are on decrescent because I must show on dialog the number from big to minor

how I can resolve ?
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: asort array but on row

Post by nageswaragunupudi »

ASort( aRow, 2, nil, { |x,y| x > y } )
Regards

G. N. Rao.
Hyderabad, India
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: asort array but on row

Post by Silvio.Falconi »

I must sort it before to show it into a xbrowse
I have the array aData
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: asort array but on row

Post by nageswaragunupudi »

for each aRow in aData
ASort( aRow, 2, nil, { |x,y| x > y } )
next

Browse adata
Regards

G. N. Rao.
Hyderabad, India
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: asort array but on row

Post by Silvio.Falconi »

Error description: Error BASE/1003 Variabile inesistente: AROW

aPrevisti:= Calcolo_Previsione(oPrevisione,primo,ba,ca,fi,ge,mi,na,pa,rm,to,ve,nz,aRuote)

for each aRow in aPrevisti
ASort( aRow, 2, nil, { |x,y| x > y } )
next
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
MGA
Posts: 1219
Joined: Mon Feb 25, 2008 2:54 pm
Location: Brasil/PR/Maringá
Contact:

Re: asort array but on row

Post by MGA »

Local aRow

aPrevisti:= Calcolo_Previsione(oPrevisione,primo,ba,ca,fi,ge,mi,na,pa,rm,to,ve,nz,aRuote)

for each aRow in aPrevisti
ASort( aRow, 2, nil, { |x,y| x > y } )
next
ubiratanmga@gmail.com

FWH17.04
FWPPC
Harbour/xHarbour
xMate
Pelles´C
TDolphin
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: asort array but on row

Post by Silvio.Falconi »

Not run ok
the array is not asort

Image
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: asort array but on row

Post by Silvio.Falconi »

perhaps with this picture Ucan understand why it is not asort for me

Image

See the red circles

ASort( aRow, 2, nil, { |x,y| x > y } )

How modify it ?
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
User avatar
byte-one
Posts: 1048
Joined: Mon Oct 24, 2005 9:54 am
Location: Austria
Contact:

Re: asort array but on row

Post by byte-one »

ASort( aRow, 2, nil, { |x,y| val(x) > val(y) } )
Regards,
Günther
---------------------------------
office@byte-one.com
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: asort array but on row

Post by Silvio.Falconi »

oopps good!!
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
Post Reply