office365,循環(huán)“l(fā) in lines”最后一個數(shù)據(jù)是 nothing。好像在所有文本內(nèi)容的最后面還有有一行 nothing,就導(dǎo)致了 字體顏色 設(shè)置的錯誤,該屬性無法作用于那個對象
![]() ![]() 打卡Lv3
|
馬作德1208
展開
|
![]() ![]() 學(xué)習(xí)達(dá)人
|
苦澀的酒
展開
|
![]() ![]() 學(xué)習(xí)達(dá)人
|
najieguo
展開
老師這段代碼不能用,報錯,是什么原因
Sub test1()
Dim rec As Rectangle, l As Line, intNum As Integer
On Error GoTo 100
For Each rec In ThisDocument.Windows(1).Panes(1).Pages(2).Selection.ShapeRange(1)
For Each l In rec.Lines
intNum = intNum + 1
If intNum Mod 2 Then
l.Range.Font.ColorIndex = wdBlue
End If
Next
Next |
承擔(dān)因您的行為而導(dǎo)致的法律責(zé)任,
本站有權(quán)保留或刪除有爭議評論。
參與本評論即表明您已經(jīng)閱讀并接受
上述條款。