Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Range of Object Global failed


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 th
run-time error. Does anyone know what would cause this and how I ge
the active object to be the Worksheet?

Thanks,
Jaso

--
JasonSel
-----------------------------------------------------------------------
JasonSelf's Profile: http://www.excelforum.com/member.php...nfo&userid=533
View this thread: http://www.excelforum.com/showthread.php?threadid=48196

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,718
Default Range of Object Global failed

Range("Formlas!B2") = "480"

Looks as if you didn't spell the sheet name correctly. Btw, no need to make
the sheet visible.

--
Jim
"JasonSelf" wrote
in message ...
|
| 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
|


  #3   Report Post  
Posted to microsoft.public.excel.programming
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


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Range of Object Global failed


Thanks,
The with method seems to have solved the problem...the spelling of
formulas was a typo in the forum, however I wouldn't have been
surprised if I had looked something that obvious over.


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

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Range Question / error 1004: method Range of object Worksheet has failed Paul Excel Programming 3 April 7th 05 02:56 PM
Range object global failure Otto Moehrbach Excel Programming 1 March 11th 05 08:55 PM
Method Rows of Object Global Failed Lynn Taylor Excel Programming 4 September 7th 04 11:35 AM
Runime Error 1004 Method Range of Object Global Failed Mohan[_5_] Excel Programming 3 May 21st 04 03:35 PM
Method Range of object global failed Dennis Excel Programming 2 April 7th 04 03:27 PM


All times are GMT +1. The time now is 09:18 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"