用isEqual方法试试,语法如下: bEqual = TextRange.isEqual(oCompareRange); 说明: Parameters oCompareRange: Required. Object that specifies the TextRange object to compare to the parent object. Return Value Boolean Returns one of the following possible values: true: oCompareRange is equal to the parent object. false: oCompareRange is not equal to the parent object.
bEqual = TextRange.isEqual(oCompareRange);
说明:
Parameters
oCompareRange: Required. Object that specifies the TextRange object to compare to the parent object.
Return Value
Boolean Returns one of the following possible values:
true: oCompareRange is equal to the parent object.
false: oCompareRange is not equal to the parent object.
是我自己搞错了
不好意思啊
一楼说的方法可以!