Range.ShowErrors 方法 (Excel)Range.ShowErrors method (Excel)

到源的错误,并返回的范围包含该单元格的单元格绘制通过从属单元格树的追踪箭头。Draws tracer arrows through the precedents tree to the cell that's the source of the error, and returns the range that contains that cell.

语法Syntax

expressionexpression. ShowErrors

expression:表示 Range 对象的变量。expression A variable that represents a Range object.

返回值Return value

VariantVariant

示例Example

如果工作表 Sheet1 上活动单元格中时出现错误,则本示例显示红色追踪箭头。This example displays a red tracer arrow if there's an error in the active cell on Sheet1.

Worksheets("Sheet1").Activate 
If IsError(ActiveCell.Value) Then 
 ActiveCell.ShowErrors 
End If

另请参阅See also

Range 对象Range Object