Hi,
I am trying to write this code but getting all sort of error. Can somebody please help me to rectify the code.
All I want is if I click the chekbox the below row from 19 to 24 will become visible else invisible.
thnks in advance.Private Sub Worksheet_Change(ByVal Target As Range) If Me.chkbox1.Value = True Then 'If Range("e18").Value = 1 Then Rows("19:24").EntireRow.Hidden = True Else Rows("19:24").EntireRow.Hidden = False End If End Sub
Last edited by fatalcore; 01-10-2012 at 12:22 PM.
fatalcore,
Give this a try:
Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = "$E$18" Then If Target.Value = 1 Then Me.Rows("19:24").Hidden = True Else Me.Rows("19:24").Hidden = False End If End If End Sub
Hope that helps,
~tigeravatar
Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble
Thanks Tigeravatar.Solved.
Last edited by fatalcore; 01-10-2012 at 12:21 PM.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks