1 UCASE$

This routine converts any lower case characters in a string to upper case.

A%=1:CALL&4083,string$

All arguments are passed by reference. You may pass multiple strings at a time. Both movable strings and fixed strings are supported; all other types are ignored.

The following program:

10 hello$="Hello,"
20 DIM world 30:$world="World!"
30 A%=1:CALL&4083,hello$,$world
40 PRINT hello$'$world

would output:

HELLO,
WORLD!

BASIC wrapper function

You can wrap up the routine as a standard BASIC function using the following snippet:

DEFFN_UCASE$(s$)LOCALA%:A%=1:CALL&4083,s$:=s$

You could then invoke it like this:

PRINT FN_UCASE$("Hello, World!")

which would output

HELLO, WORLD!

See Also