2016-05-15 90 views

回答

0

得到答案现在:) 下面是解决方案:

Sheet1.Cells(i, 9).Characters(Len(Sheet1.Cells(i, 9).Value), 1).Font.ColorIndex = 3 

感谢。

0

请试试这个:

Sub ColorTextv() 

    Dim i As Long 
    Dim text As String 
    ' Change as per your requrement. I used it for testing purpose 
    text = Cells(1, 9).Value 

    For i = 1 To Len(text) 
    If i = Len(text) Then 
    Cells(1, 9).Characters(i, 9).Font.ColorIndex = 3  
    'You can change by mentioning color also   
    'Cells(1, 9).Characters(i, 9).Font.Color = vbRed 
    End If 
    Next 

End Sub 
相关问题