Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

When to use ucase vs ucase in vb6?


Asked by Ahmed Dalton on Dec 14, 2021 FAQ



String functions in VB6 exist in pairs - one accepts and returns Variants, the other one accepts and returns Strings. The strongly typed ones end with $. Both are useful in different contexts, so if you have a string variable to begin with, it's better to use UCase$ than UCase. – GSerg Apr 8 '15 at 20:31
Moreover,
It can be used as a VBA function (VBA) in Excel. As a VBA function, you can use this function in macro code that is entered through the Microsoft Visual Basic Editor. The string that you wish to convert to upper-case. The UCASE function returns a string value.
And, The required string argument is any valid string expression. If string contains Null, Null is returned. Only lowercase letters are converted to uppercase; all uppercase letters and nonletter characters remain unchanged. This example uses the UCase function to return an uppercase version of a string.
In this manner,
If you are already searching for the UPPER function in VBA then you will not find it not even with Worksheet Function class. In VBA it is completely a different and short name function i.e. “UCASE”. Here “U” stands for “UPPER”, so formula reads “UPPERCASE”. Now, look at the syntax of the Excel VBA UCASE function.
Just so,
This is possible by using the UCase, LCase and StrConv functions. These functions are important when manipulating strings in VBA, as VBA is case sensitive.