c# - I'm creating a Windows Forms application, how can I ask the user to enter name in block letters? -


i have started windows forms application. when registration form runs, should ask user enter name in block letters, text box should not left null, , how create text should alpha numeric?

to set textbox uppercased can run this:

textbox.charactercasing = charactercasing.upper; 

to make non-null-able, need check if there text on on button press event. this:

if(string.isnullorwhitespace(textbox.text)) {    messagebox.show("you need input name."); } 

remember change textbox textbox name.


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -