From WikiChip
Difference between revisions of "mirc/identifiers/$sorttok"
< mirc‎ | identifiers

m
Line 1: Line 1:
{{mirc title|$sorttok identifier}}'''$sorttok''' sorts the token in text.
+
{{mirc title|$sorttok identifier}}'''$sorttok''' sorts the tokens in text. '''$sorttokcs''' is the case sensitive version
  
 
== Synopsis ==
 
== Synopsis ==
<pre>$sorttok(<list>,C[,nrca])</pre>
+
<pre>$sorttok(<list>,C[,nrca])
 +
$sorttokcs(<list>,C[,nrca])</pre>
  
 
== Parameters ==
 
== Parameters ==
Line 42: Line 43:
 
* {{mIRC|$remtok}}
 
* {{mIRC|$remtok}}
 
* {{mIRC|$reptok}}
 
* {{mIRC|$reptok}}
* {{mIRC|$sorttokcs}}
 
 
* {{mIRC|$wildtok}}
 
* {{mIRC|$wildtok}}
 
{{mIRC identifier list}}
 
{{mIRC identifier list}}
  
 
[[Category:mIRC identifiers|sorttok]]
 
[[Category:mIRC identifiers|sorttok]]

Revision as of 10:13, 15 February 2018

$sorttok sorts the tokens in text. $sorttokcs is the case sensitive version

Synopsis

$sorttok(<list>,C[,nrca])
$sorttokcs(<list>,C[,nrca])

Parameters

  • <list> - The list of tokens (can be empty)
  • <C> - The ascii number (or code point) of the character seperating the tokens
  • ncra - default is alphabetical sort (ASCII order) if 3rd parameter not used, n = numeric sort; c = channel prefix sort; r = reverse; a = ASCII sort

Note: 'a' sort is case-insensitive. For case-insensitive use $sorttokcs

Properties

None

Example

//echo -a $sorttok(C a c b A B,32,a)
 
//echo -a Sorted in ASCII order: $sorttok( $chr(10004) $chr(9650) $chr(9660) , 32)
alias NumericMax {
  return $gettok($sorttok($1- , 32 , rn),1,32)
}

Compatibility

Added: mIRC v4.7
Added on: 09 Dec 1996
Note: Unless otherwise stated, this was the date of original functionality.
Further enhancements may have been made in later versions.


See also

[Expand]
v · d · e mIRC identifier list