mIRC Home    About    Download    Register    News    Help

Print Thread
Sorting numbers in combo dialog #137683
17/12/05 02:44 PM
17/12/05 02:44 PM
Joined: Dec 2004
Posts: 40
B
bog__ Offline OP
Ameglian cow
bog__  Offline OP
Ameglian cow
B

Joined: Dec 2004
Posts: 40
I have new problem

dialog rat {
title "echo"
size -1 -1 400 320
option dbu
combo 900, 260 60 110 120, tab 5 size drop sort vsbar %result multi
button "New Scan", 109, 140 260 110 30, flat
}
on *:DIALOG:rat:init:0 {
did -a $dname 900 5
did -a $dname 900 8
did -a $dname 900 10
did -a $dname 900 6
did -a $dname 900 5
did -a $dname 900 1
did -a $dname 900 453
did -a $dname 900 123
did -a $dname 900 22
did -a $dname 900 23222
did -a $dname 900 888
did -a $dname 900 3211
did -a $dname 900 144
did -a $dname 900 2321
did -a $dname 900 132
did -a $dname 900 45435
did -a $dname 900 223
did -a $dname 900 453
did -a $dname 900 3223
did -a $dname 900 35555
did -a $dname 900 88
}
and he is sorthing them like this

1
10
123
132
144
22
223
2321
23222
2311
3223
35555
453
......

But i realy need that data in combo to be sorted like this

1
10
22
123
132
144
223
453
2311
2321
3223
23222
35555
......
I whas serching mirc help and forum for the solution but i dident finde anything simular. Can someone help?

Re: Sorting numbers in combo dialog #137684
17/12/05 02:58 PM
17/12/05 02:58 PM
Joined: Nov 2005
Posts: 42
England
A
Aenei Offline
Ameglian cow
Aenei  Offline
Ameglian cow
A

Joined: Nov 2005
Posts: 42
England
could you put your numbers in
0001
0010
0022
0123
etc?

Re: Sorting numbers in combo dialog #137685
17/12/05 03:05 PM
17/12/05 03:05 PM
Joined: Dec 2004
Posts: 40
B
bog__ Offline OP
Ameglian cow
bog__  Offline OP
Ameglian cow
B

Joined: Dec 2004
Posts: 40
hm good idea i can then try to use
$len(text)
and if $len(text) is 1 or beager i can add 0
write 2.txt did -a $chr(36) $+ dname 900 0000 $+ %3 %2
and then reload
/.load -rs 2.txt
/dialog -m rat rat
I will try it, hope it will work

Re: Sorting numbers in combo dialog #137686
17/12/05 03:21 PM
17/12/05 03:21 PM
Joined: Dec 2004
Posts: 40
B
bog__ Offline OP
Ameglian cow
bog__  Offline OP
Ameglian cow
B

Joined: Dec 2004
Posts: 40
Its working. Thanks on the idea Aenei
laugh

Re: Sorting numbers in combo dialog #137687
17/12/05 03:29 PM
17/12/05 03:29 PM
Joined: Feb 2004
Posts: 2,019
Leuven, Belgium
FiberOPtics Offline
Hoopy frood
FiberOPtics  Offline
Hoopy frood

Joined: Feb 2004
Posts: 2,019
Leuven, Belgium
Remove the sort option from the combo, and after adding the numbers issue this command:

//filter -ciout 1 32 rat 900 rat 900

Take a look at /didtok btw.


Gone.