I have designed a UserForm that gathers over 40 pieces of information required to perform an annuity calculation. The data includes dates, dollar amounts, percentages, other numeric data (such as the term in years), and text information (such as name).
I have 2 questions:
1. Is there an easy way to format the data? For example, if a user keys in 2.5 as a percentage, I would like the form to show 2.5%. I think I read somewhere that you don't want to have an OnClick event for all the fields as it will slow the application down, but it also seems to be a nightmare in terms of the amount of code there is. (I also ultimately want to save the data to a spreadsheet as a value that will be used in the calculation i.e. as 0.025.)
2. I am in the process of writing code to verify that the data makes sense. I have used used some dropdown lists and radio buttons for some of the input, but a lot of the data is being entered in textboxes. Do I have to write code for EVERY textbox to check if it's numeric data if it's supposed to be? Or to check that the data is a valid date? The amount of code that I'm writing seems to be getting out of hand.
I appreciate any advice. Thanks.
I have 2 questions:
1. Is there an easy way to format the data? For example, if a user keys in 2.5 as a percentage, I would like the form to show 2.5%. I think I read somewhere that you don't want to have an OnClick event for all the fields as it will slow the application down, but it also seems to be a nightmare in terms of the amount of code there is. (I also ultimately want to save the data to a spreadsheet as a value that will be used in the calculation i.e. as 0.025.)
2. I am in the process of writing code to verify that the data makes sense. I have used used some dropdown lists and radio buttons for some of the input, but a lot of the data is being entered in textboxes. Do I have to write code for EVERY textbox to check if it's numeric data if it's supposed to be? Or to check that the data is a valid date? The amount of code that I'm writing seems to be getting out of hand.
I appreciate any advice. Thanks.