|
ということからデータは、数値ですか?
に応えがないのですが、ゼロという言葉から、数値だと考えて
作ってみました。
Dim a As Long
Sub test()
Dim i As Long, j As Long
Dim myVal As Long
a = 1
With Sheets("Sheet1")
For i = 4 To 100
For j = 0 To 3
myVal = .Cells(i, a + j).Value
If myVal = 0 Then
.Cells(i, a + 26).Value = 1
Exit For
End If
Next
myVal = Empty
Next
On Error Resume Next
.Columns(a + 26).SpecialCells(xlCellTypeConstants, 1).EntireRow.Hidden = True
On Error GoTo 0
End With
End Sub
'=============================================================
Sub All_data()
With Sheets("Sheet1")
.Rows.Hidden = False
.Columns(a + 26).ClearContents
End With
End Sub
|
|