Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 208
Default Run-Time Error 1004/ unable to set the hidden property of the rang

I have a spreadsheet that has the same survey details on repeated down the
page.
There is a radio button 1-13 and by clicking in one of them you get the
corresponding number of survey sections. I want most of the page protected,
to stop people tinkering with it but when it is locked I get the Run-Time
error 1004 when selecting one of the radio buttons

copy of VB below

Can anyone help

If I put the Me.Unprotect at the start and Me.Prptect at end it works but
ask for password to be entered which defeats the object.

Private Sub OptionButton_1_Click()

If Me.OptionButton_1.Value = -1 Then
Rows("37:470").Hidden = True


End If

End Sub

Private Sub OptionButton_10_Click()

If Me.OptionButton_10.Value = -1 Then
Rows("37:360").Hidden = False
Rows("362:470").Hidden = True

End If

End Sub

Private Sub OptionButton_11_Click()

If Me.OptionButton_11.Value = -1 Then
Rows("37:397").Hidden = False
Rows("398:470").Hidden = True

End If

End Sub
Private Sub OptionButton_12_Click()

If Me.OptionButton_12.Value = -1 Then
Rows("37:433").Hidden = False
Rows("434:470").Hidden = True

End If

End Sub
Private Sub OptionButton_13_Click()

If Me.OptionButton_13.Value = -1 Then
Rows("37:470").Hidden = False
End If

End Sub

Private Sub OptionButton_2_Click()

If Me.OptionButton_2.Value = -1 Then
Rows("37:73").Hidden = False
Rows("74:470").Hidden = True
End If

End Sub

Private Sub OptionButton_3_Click()

If Me.OptionButton_3.Value = -1 Then
Rows("37:109").Hidden = False
Rows("110:470").Hidden = True
End If

End Sub

Private Sub OptionButton_4_Click()

If Me.OptionButton_4.Value = -1 Then
Rows("37:145").Hidden = False
Rows("146:470").Hidden = True
End If

End Sub

Private Sub OptionButton_5_Click()

If Me.OptionButton_5.Value = -1 Then
Rows("37:181").Hidden = False
Rows("182:470").Hidden = True
End If

End Sub

Private Sub OptionButton_6_Click()

If Me.OptionButton_6.Value = -1 Then
Rows("37:217").Hidden = False
Rows("218:470").Hidden = True
End If

End Sub

Private Sub OptionButton_7_Click()

If Me.OptionButton_7.Value = -1 Then
Rows("37:253").Hidden = False
Rows("254:470").Hidden = True
End If

End Sub

Private Sub OptionButton_8_Click()

If Me.OptionButton_8.Value = -1 Then
Rows("37:289").Hidden = False
Rows("290:470").Hidden = True
End If

End Sub

Private Sub OptionButton_9_Click()

If Me.OptionButton_9.Value = -1 Then
Rows("37:325").Hidden = False
Rows("326:470").Hidden = True
End If

End Sub





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
Hiding Rows Error - "Runtime Error 1004 - Unable to set the hidden property of the range class" Punsterr Excel Programming 2 April 9th 07 05:32 PM
Run time error 1004 - unable to get the chartObjects property of the worksheet class hedgehog1 Excel Programming 1 April 10th 06 08:10 PM
Run Time Error 1004 Unable to set hidden property Lester Lee Excel Programming 3 July 22nd 04 03:31 AM
Run-time Error '1004' Unable to get the findnext property... Tom Ogilvy Excel Programming 0 July 12th 04 04:27 PM
Run time error 1004 - Unable to get add property of the buttons class Mark[_37_] Excel Programming 0 March 1st 04 09:48 AM


All times are GMT +1. The time now is 09:37 AM.

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

About Us

"It's about Microsoft Excel"