From: Family Tree Mike on
Herfried K. Wagner [MVP] wrote:
> Family Tree Mike schrieb:
>>> Also, C# does not allow using "UCase" unqualified even if you're
>>> referencing the VisualBasic assembly.
>>>
>>> Neither 'UCase' nor 'ToUpper' modify the string in-place. Both the
>>> VB global function and the .NET string 'ToUpper' method return new
>>> strings.
>>
>> Well, this is a VB.net question...
>>
>> For what it is worth, you can use the following in C#:
>>
>> static void Main(string[] args)
>> {
>> string s = Microsoft.VisualBasic.Strings.UCase("Fred");
>> Console.WriteLine(s);
>> Console.ReadKey();
>> }
>>
>> Just add a reference to Microsoft.VisualBasic.
>
> Yep, but you are using 'UCase' qualified by the namespace and module
> name. C# doesn't support importing modules, making it possible to use
> the function without further qualification.
>


Oh, sorry. When I read it, I missed the word unqualified.

--
Mike