View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Jim Thomlinson[_4_] Jim Thomlinson[_4_] is offline
external usenet poster
 
Posts: 1,119
Default Range of Object Global failed

Private Sub OptionButton2_Click()
with Sheets("Formulas")
.Visible = True
.Range("B2") = "480" <-----
.Visible = False
end with
Sheets("Panel").Select
End Sub

--
HTH...

Jim Thomlinson


"JasonSelf" wrote:


I am getting a runtime error '1004'
Method 'Range' of object 'Global' failed

Private Sub OptionButton2_Click()
Sheets("Formulas").Visible = True
Range("Formlas!B2") = "480" <-----
Sheets("Formulas").Visible = False
Sheets("Panel").Select
End Sub

when I originally wrote this code it worked, however now I get the
run-time error. Does anyone know what would cause this and how I get
the active object to be the Worksheet?

Thanks,
Jason


--
JasonSelf
------------------------------------------------------------------------
JasonSelf's Profile: http://www.excelforum.com/member.php...fo&userid=5330
View this thread: http://www.excelforum.com/showthread...hreadid=481967