I have 32 checkboxes on a userform for Yes/No answers to 16 questions.
Question 1 Checkbox 1 for yes Checkbox 2 for no...etc.
Each yes/no checkbox adds a value to a cell on active spreadsheet.
When the user in done (in their mind anyways) They click a command button to enter another person responses. Right now the CB clears all the checkboxes and moves 1 line down on the spreadsheet for the next person.
In that code attached to the command button I want it to check to make sure at least 1 response to each question has been chosen.
If checkbox1.value = false and checkbox2.value = false then Msgbox "You did not answer question 1"
I created this same code for all 16 questions.
The user corrects the missing answer(s) and clicks the CB again to enter another person responses. Here is where my code stops. Once it has veified that at least 1 repsonse was chosen for each question I need to reset the checkboxes and go on to the next person answers.
I haven't done VB in sometime so my code is pretty simplistic and I've probably typed 16 lines for something that more advance code would replace in 1.
I hope I explained this well enough for you to understand.
Thanks for reading
Jamie (Connecticut/USA)
Question 1 Checkbox 1 for yes Checkbox 2 for no...etc.
Each yes/no checkbox adds a value to a cell on active spreadsheet.
When the user in done (in their mind anyways) They click a command button to enter another person responses. Right now the CB clears all the checkboxes and moves 1 line down on the spreadsheet for the next person.
In that code attached to the command button I want it to check to make sure at least 1 response to each question has been chosen.
If checkbox1.value = false and checkbox2.value = false then Msgbox "You did not answer question 1"
I created this same code for all 16 questions.
The user corrects the missing answer(s) and clicks the CB again to enter another person responses. Here is where my code stops. Once it has veified that at least 1 repsonse was chosen for each question I need to reset the checkboxes and go on to the next person answers.
I haven't done VB in sometime so my code is pretty simplistic and I've probably typed 16 lines for something that more advance code would replace in 1.
I hope I explained this well enough for you to understand.
Thanks for reading
Jamie (Connecticut/USA)