Nothing now :) i figured the last part out.
My intention above (After figuring out how to error check the last name entered by the user) was to convert the first letter to upper case. I jsut figured that out.
Now..if anyone would like to put their input in haha, i am attempting to create the same type of error checking function to validate a phone type...here is the information that i have coded so far, followed by the instructions on how to validate. I haven't gotten that far, so it will take me a few minutes to add enough code to show you that I am still doing it myself rather than asking for an answer...but in case you feel like having an idea before i submit my idea :)
1 2 3 4 5 6 7 8 9 10 11
|
// enumerated types
enum PhoneType {HOME, WORK, CELL};
// struct
struct RecordType
{
string socialSecurityNumber;
string lastName;
string phoneNumber;
PhoneType typePhone;
};
|
Phone type enumerated type
Options for enumerated type are: HOME, WORK, CELL
(define them in this order, so their ordinal values will be
HOME = 0, WORK = 1, and CELL = 2 when saved to the data file).
NOTE: When refering to enumerated values in the program, the code should never use the ordinal
values. It should always use the HOME, WORK, CELL values.
Verify that a valid value is entered for phone type
(make sure your program tells the user what the choices are,
and how to enter the correct value).