Hi. I have created an excel quiz which asks 4 radio and one check box question. If a person gets A question right, it is linked to a box which becomes 1. A cell at the bottom adds these up and my task is to create a function that will turn the number that someone got right into the same number of stars. Here is my code below, first it comes up with #Value and then something about block ifs. Please tell me what I am doing wrong.
Public Function Stars(number As Integer)
If number = 0 Then Stars = ""
End If
If number = 1 Then Stars = "*"
End If
If number = 2 Then Stars = "**"
End If
If number = 3 Then Stars = "***"
End If
If number = 4 Then Stars = "****"
End If
If number = 5 Then Stars = "*****"
End If
End Function
Bookmarks