How to remove lowercase on a textbox?

后端 未结 11 1872
难免孤独
难免孤独 2020-12-31 02:47

I\'m trying to remove the lower case letters on a TextBox..

For example, short alpha code representing the insurance (e.g., \'BCBS\' for \'Blue Cross B

11条回答
  •  没有蜡笔的小新
    2020-12-31 03:46

    Without Regex:

    string input = "Blue Cross Blue Shield";
    string output = new string(input.Where(Char.IsUpper).ToArray());
    Response.Write(output);
    

提交回复
热议问题