forum

Home / DeveloperSection / Forums / What is better solution for validate form TextBoxs value?

What is better solution for validate form TextBoxs value?

Anonymous User141023-Sep-2013

In my system has many forms for insert and edit database registers

But before to save date in database, I need validate any camp, validate it values is empty or not, validate TextBox.Text lenght, etc...

I validated they with many many if's

if (tbName.Text.Equals("")) { }

if (tbPass.Password.Equals("")) { }

if (tbEmail.Text.Equals("")) { }

if (tbTelephone.Text.Equals("")) { }

if (tbNome.Text.Length < 4) { }

if (tbPass.Password.Length < 5) { }

if (!tbEmail.Text.Contains('@')) { }

but it is very no efficiency and I don't know any other solution for this

What solution is usual for this?


Updated on 23-Sep-2013
I am a content writter !

Can you answer this question?


Answer

1 Answers

Liked By