UCase ASP String Function

UCase ASP String Function
UCase is a commonly used ASP function that allows you to convert all characters in a string to their upper case versions. It only takes in one parameter:

* The string variable to operate on

The original string variable is not altered.

Let's say you have a form in which a user types in a model number. You then want to compare that model number against a database of models to get more information. You have millions of model numbers, so you don't want to do a drop down or something like that. But if the user starts typing in lowercase letters, say "xyg142" or "Xyg142", you will have trouble doing a search properly. So you use:

ModelNo = UCase(ModelNo)

That would turn both of the above examples into "XYG142" without the user having to think about which way they enter the information.

ASP String Functions

Introduction to ASP Ebook

Download this ebook to get everything you need to know about learning ASP - from a step by step tutorial to function lists, sample code, common errors and solutions, and much more! 101 pages.




RSS
Related Articles
Editor's Picks Articles
Top Ten Articles
Previous Features
Site Map





Content copyright © 2023 by Lisa Shea. All rights reserved.
This content was written by Lisa Shea. If you wish to use this content in any manner, you need written permission. Contact Lisa Shea for details.