On 2002-02-20 21:38, Damon Ostrander wrote:
Yes, you can do both. To assign a cell value to a variable:
Dim CellVal As Variant
CellVal = [B4].Value
puts the value from cell B4 into the variable named CellVal.
To assign a variable from an InputBox:
Dim CellVal As Variant
CellVal = Application.InputBox("Enter User Name", Type:=3)
where the Type:=3 indicates that you are expecting the user to enter a text string (set other type values for other data types)