Hey Folks,
I'm trying to generate an InputBox that allows the user to define the variable that will determine the range for the values spit out by a Macro.
inputvalue = Application.InputBox(prompt:="Please enter a number.", Title:="Enter a Number", Type:=1)
If inputvalue = ("1") Then Range = ("f2")
If inputvalue = ("2") Then Range = ("f2:f3")
If inputvalue = ("3") Then Range = ("f2:f4")
If inputvalue = ("4") Then Range = ("f2:f5")
If inputvalue = ("5") Then Range = ("f2:f6")
If inputvalue = ("6") Then Range = ("f2:f7")
If inputvalue = ("7") Then Range = ("f2:f8")
If inputvalue = ("8") Then Range = ("f2:f9")
If inputvalue = ("9") Then Range = ("f2:f10")
End If
inputvalue= ("0")
I keep getting an argument not optional error, and I'm unsure as to what it means here. I'm relatively new at this, and could use any help!
Thanks folks,
NP
Bookmarks