Hi,
there is a problem browsing an array using the SORT command and non progressive elements.
In this self-contained sample I have a 6 elements array and I want to browse only elements 1 and 6.
As you can see if you try to change the order of the date column then the order is not correct.
See www.softwarexp.co.uk/beta/image1.png to see an image of the problem
Any ideas ?
Thanks in advance
#include "FiveWin.ch"
#include "xbrowse.ch"
function Main()
local oDlg, oBrw, aArray
set date french
set epoch to 1920
aArray:={}
aadd(aArray,{"Marc","Nil1","Nil2","Nil3","Nil4",ctod("31/12/2003")})
aadd(aArray,{"Luc","Nil1","Nil2","Nil3","Nil4",ctod("30/05/2004")})
aadd(aArray,{"George","Nil1","Nil2","Nil3","Nil4",ctod("31/12/2004")})
aadd(aArray,{"Simon","Nil1","Nil2","Nil3","Nil4",ctod("31/12/2005")})
aadd(aArray,{"Janie","Nil1","Nil2","Nil3","Nil4",ctod("31/12/2006")})
aadd(aArray,{"Robert","Nil1","Nil2","Nil3","Nil4",ctod("31/12/2007")})
aadd(aArray,{"Melanie","Nil1","Nil2","Nil3","Nil4",ctod("31/12/2008")})
DEFINE DIALOG oDlg SIZE 300, 200
@0,0 XBROWSE oBrw OF oDlg array aarray
oBrw:nMarqueeStyle := MARQSTYLE_HIGHLROW
oBrw:lRecordSelector := .f.
ADD COLUMN oCol TO XBROWSE oBrw DATA ARRAY ELEM 1;
HEADER "Name" SIZE 100 ORDER 1
ADD COLUMN oCol TO XBROWSE oBrw DATA ARRAY ELEM 6;
HEADER "Date" SIZE 80 ORDER 2
oBrw:CreateFromCode()
ACTIVATE DIALOG oDlg CENTER
return nil