mikieprojects48
New Member
- Joined
- Jun 5, 2011
- Messages
- 9
I'm new to vba and going through the Dummies for VBA book now, one of the example exercises is for CUBEROOT.
Sub CubeRoot()
Num = InputBox("Enter a positive number")
MsgBox Num ^ (1 / 3) & " is the cube root. "
The only way that I can get the macro to work is by removing the Option Explicit from the text window. I read that option explicit protects the code and if you put the letters dim in front of the lines the macro will work not able to get the right combination any help would be appreciated
mikie48
Sub CubeRoot()
Num = InputBox("Enter a positive number")
MsgBox Num ^ (1 / 3) & " is the cube root. "
The only way that I can get the macro to work is by removing the Option Explicit from the text window. I read that option explicit protects the code and if you put the letters dim in front of the lines the macro will work not able to get the right combination any help would be appreciated
mikie48