小编RCo*_*978的帖子

如何根据截止日期条件格式化Excel 2010以在新列中触发标志图标

我有一排截止日期,如果截止日期已过期,我希望用图标标记.有没有办法使用条件格式来触发图标?if then语句应该是:

如果今天()>"截止日期",则在第2列中标记带有红旗图标的单元格.

第1栏截止日期

第2栏(如果到期日为红旗)

excel excel-2010

4
推荐指数
2
解决办法
7万
查看次数

使用以下Excel 2010 VBA溢出错误6

以下代码将按照我想要的方式正确格式化我的模板.但是,如果模板为空并且用户点击工作表上的准备上传按钮,我将收到溢出错误6.是否有任何方法可以删除导致此错误的原因?

    Sub PrepForUpload()

Dim cel As Range, rng As Range

Set rng = Range("A2", Range("A65536").End(xlUp))

For Each cel In rng

    If cel.Value = "" Then

        If cel.Offset(, 2).Value = "" Then
            cel.EntireRow.Delete

        End If

    End If

    Next cel

Dim rowNumber As Integer
With Sheets("Initiatives")

If Len(.Cells(2, 1)) = 0 Then

rowNumber = .Cells(2, 1).End(xlDown).End(xlDown).Row + 1

Else: rowNumber = .Cells(2, 1).End(xlDown).Row + 1

End If

.Rows(rowNumber & ":" & .Rows.Count).Clear

End With


End Sub
Run Code Online (Sandbox Code Playgroud)

调试指向以下行作为问题:

rowNumber = .Cells(2, 1).End(xlDown).End(xlDown).Row + …
Run Code Online (Sandbox Code Playgroud)

excel vba

3
推荐指数
1
解决办法
2万
查看次数

标签 统计

excel ×2

excel-2010 ×1

vba ×1