Someone may help me?
here's the program:
Code: Select all
Dim array$(10000)
filename$ = OpenFileRequester("Seleziona un file da ordinare in ordine ALFABETICO", "*.csv", "Comma Separated Value", 0)
If filename$="" Or filename$=".csv"
MessageRequester("Errore", "Nessun file selezionato", #PB_MessageRequester_Ok)
End
EndIf
r = OpenFile(1, filename$)
If r=0
MessageRequester("Errore", "Nome file invalido", #PB_MessageRequester_Ok)
End
EndIf
pos=1
eof=0
Repeat
text$ = ReadString()
If text$=""
eof=1
Goto fondo
EndIf
array$(pos) = text$
pos=pos+1
fondo:
Until eof=1
CloseFile(1)
quantity=pos-1
SortArray(array$(),2)
DeleteFile(filename$)
OpenFile(1,filename$)
pos=1
Repeat
If array$(pos)<>""
WriteStringN(array$(pos))
EndIf
pos=pos+1
Until pos=9999
CloseFile(1)
MessageRequester("Finito", "Ordinati "+Str(quantity)+" elementi", #PB_MessageRequester_Ok)
Code: Select all
Fifth Gear,Racing game,5thgear,1988,Rack it,44,,2,
Five a Side,Soccer Game,5aside,,Advantage,28,,3,
Four Corners,Cards Game,4corn,1996,Softdisk Inc.,17,,3,
Lunattack,Action,3d_luna,,Hewson,23,,3,
Nine Princes in Amber,Adventure,9princes,1985,Telarium Corp.,320,,2,
Seven Cities Of Gold,Adventure,7cities,1984,Ozark Softscape,64,,2,
The Three Musketeers,Adventure,3_musketeers,1987,Computer Novels,164,,1,
please help!
thx ..::Yuri::..