0

C# forms

how can i use input in c# forms( NOT CONSOLE). What code i need to use? thx

21st Oct 2017, 9:16 AM
Vladimir
Vladimir - avatar
4 Réponses
21st Oct 2017, 9:40 AM
Daniel
Daniel - avatar
+ 5
I'm not sure what you really mean, but string comparison goes something like: string myString = "Vladimir"; string otherString = "vladimir"; // note different 'v' // Case sensitive comparison bool equality = myString.Equals(otherString, StringComparison.Ordinal); // equality = False // Case insensitive comparison bool equality = myString.Equals(otherString, StringComparison.OrdinalIgnoreCase); // equality = True Hope I get you right :)
21st Oct 2017, 10:10 AM
Ipang
+ 1
i meant about a program which would ask any text from user and would compare it with predefined text in code. Like "write your name", the text field is opening, after filling the field and pressing "enter" the program will compare this text with mine
21st Oct 2017, 9:50 AM
Vladimir
Vladimir - avatar