Hello! =)
I'm trying to add a msgbox function into my excel macro where it would pop up specifically when a cell in my spreadsheet is empty instead of filled in. Here's a piece of the script:
Msg = Msg & Range("B4".Value & "^"
If Range("B4".Value = "" Then
MsgBox("You must enter a number!", vbOKOnly, "STOP!" = vbOK
Stop
Else
Msg = Msg & Range("B5".Value & "^"
When I try to run this, I get a compile error that says, "Function call on left-hand side of assignment must return Variant or Object". Does anyone have a solution?
Thanks,
Jisoo22
I'm trying to add a msgbox function into my excel macro where it would pop up specifically when a cell in my spreadsheet is empty instead of filled in. Here's a piece of the script:
Msg = Msg & Range("B4".Value & "^"
If Range("B4".Value = "" Then
MsgBox("You must enter a number!", vbOKOnly, "STOP!" = vbOK
Stop
Else
Msg = Msg & Range("B5".Value & "^"
When I try to run this, I get a compile error that says, "Function call on left-hand side of assignment must return Variant or Object". Does anyone have a solution?
Thanks,
Jisoo22