Have a few quick questions about a program I'm writing
Ok I have the general idea of what i want in this program, but I just need some help in some areas.
For one thing I want to make sure in the email textbox that the user must enter text, a "@" and a "." then more text in that perticular order. As it is right now I used an if statement that checks that the characters are both there but does not make sure they are placed in that specific order
here is a sample of the code i used
Code:
private void txtEmail_TextChanged(object sender, EventArgs e)
{
//We will use "contains to make sure the user enters
// "@" and "." in their email address
Email = txtEmail.Text.Trim();
Email = txtEmail.Text;
string CheckEmailChar1 = "@";
string CheckEmailChar2 = ".";
if (Email.Contains(CheckEmailChar1) && Email.Contains(CheckEmailChar2))
{
}
else
{
MessageBox.Show("Please include @ and . in the email feild");
}
}
I am aslo having a aproblem in the "Loan amount requested textbox and I'm not sure exactly why. The program runs but as soon as I input anything into that textbox, I end up with an error and the program stops running.
I am a bit tired so I hope my post was still somewhat coherent, I will get back to this post later and try and get this fixed fairly soon. You will find the full program in the zip file attached.
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.