This text is missing some spaces, please add them: PrivateSubWorksheet_Change(ByValTargetAsRange)'Thismacroshowshowtohiderowsautomaticallyby'typingacertainorrandomletterincolumnA.It'doesn'thavetobecolumnA-itcouldbeanycolumn.'Intheexampleallhiddenrowsaremadevisible,'ifcellA1getsavalueof0(zero).OnErrorResumeNext'Ifthechangewasn'tincolumnA,weexit.
Private Sub Worksheet_Change(ByVal Target As Range) 'This macro shows how to hide rows automatically by 'typing a certain or random letter in column A. It 'doesn't have to be column A - it could be any column. 'In the example all hidden rows are made visible, 'if cell A1 gets a value of 0 (zero). On Error Resume Next 'If the change wasn't in column A, we exit.