This documentation was styled with a demo skin from the Premium Pack 4 add-on for Help & Manual. The contents of the skin are encrypted and not configurable. You can only publish HM projects with this skin. You cannot edit it or change it.
This version is copyright and may only be used for local testing purposes. It may not be distributed.
Please purchase the full version of the Premium Pack to get the configurable skins and remove this notice. The package will also include the Toolbox configuration utility for Premium Pack skins.
Description
Return the largest (maximum) value from a list of strings.
Syntax
s = MAX$(s1 [, s2 [, s3 ... [, s...]]])
Returns
String
Parameters
Name |
Type |
Optional |
Meaning |
s1 |
String |
No |
The first string |
s2, ... |
String |
Yes |
Any successive string |
Remarks
Restrictions
MAX$ is case sensitive
See also
Examples
Thanks to Abraxas for the following script example
' Usage of the MAX$ Keyword example
' Usage of the MIN$ Keyword example
' Attention: MIN$ and MAX$ are case sensitive!
Dim MyNo1String As String VALUE "What" ' ascii values 87 104 97 116
Dim MyNo2String As String VALUE "is" ' ascii values 105 115
Dim MyNo3String As String VALUE "the" ' ascii values 116 104 101
Dim MyNo4String As String VALUE "Value" ' ascii values 86 97 108 117 101
Dim sMsg As String
sMsg += "String 1 " & MyNo1String & $CRLF
sMsg += "String 2 " & MyNo2String & $CRLF
sMsg += "String 3 " & MyNo3String & $CRLF
sMsg += "String 4 " & MyNo4String & $CRLF & $CRLF
smsg += "MAX$ " & MAX$(MyNo1String, MyNo2String, MyNo3String, MyNo4String) & $CRLF
smsg += "MIN$ " & MIN$(MyNo1String, MyNo2String, MyNo3String, MyNo4String) & $CRLF
MSGBOX 0, sMsg