Hello, I have a text box that has code in it that checks to make sure
the first char is a '%' and the last is a '^' because that is how our
CC's work. However, if I want someone to be able to type into it,
they have to type a % first and the a carrot at the end. Is there
anyway to avoid that...here is the code...I didn't write it, butit is
how the boss wants it:
if (e.KeyChar == '^')
IsSwipeStarted = false;
if (IsSwipeStarted)
{
if (char.IsNumber(e.KeyChar) == false)
e.Handled = true;
}
else
e.Handled = true;
if (e.KeyChar == '%')
IsSwipeStarted = true;
if (e.KeyChar == '\r')
btnCardParse_Click(null, null);
TIA:
Rick