
teheheheh
Hi all i have this code and when I type a zero, which is part of a phone number it goes!! into the wild blue yonder i have tired changing the LE to a number format, but the whole thing buggers up so here is the code
// Formats Telephone Number - this version checks for proper amount of digits and
// notifies user if there is a problem my element is named HomePhone
var vHPhone as String
var vNewHPhone As String
var vhphonecount
var vhpnentered
Vhpnentered = @num(Cellphone Number)
vhphonecount = @num(@len(vhpnentered))
If vhphonecount > 0
If vhphonecount = "10"
{
// @color(Home Phone,1,1)
vHPhone = @Num(Cellphone Number)
vNewHPhone = @Left(vHPhone, 3) + @Mid(vHPhone, 3, 3) + "-" + @Right(vHPhone, 4)
Cellphone Number = vNewHPhone
}
else
{
@color(Cellphone Number,7,1)
@msgbox("The Cellphone Number needs to be Exactly 10 Digits", "The numbers you entered " +
@num(Cellphone Number),"is : " + Vhphonecount + " Digits Please check The Cellphone Number and Re-enter")
}
Help please