10/06/25 09:49:57
>>637
Private Sub Worksheet_Change(ByVal Target As Range)
For i = 1 To Len(Target)
If IsNumeric(Mid(Target, i, 1)) Then
Target.Characters(Start:=i, Length:=1).Font.ColorIndex = 3 '3は赤色
End If
Next
End Sub
>>638
Sub a()
Dim unko
unko = "うんこ" '変えたい文字
Dim unkolen
unkolen = Len(unko)
If Selection.Row = 1 And Selection.Column = 1 Then 'とりあえずA1セル限定
For i = 1 To Len(Cells(1, 1))
If Mid(Cells(1, 1).Value, i, unkolen) = unko Then
ActiveCell.Characters(Start:=i, Length:=unkolen).Font.Size = 15 'フォントサイズ
End If
Next
End If
End Sub