在ahk中寻找文本字符计数功能

Looking for text character counting functionality in ahk

ahk 有文字统计功能吗?

我想制作一个字符计数器,如果我按 ctrl+alt+-,将打开一个输入框。并且将计算变量值中使用的字符数。

You can start with:

<^<!-::
InputBox, Text1, Count, Paste the text in the text box to count the number of characters it has, and find things in that text
MsgBox text:You typed %Text1%.`nCharacters:
return

有答案吗?谢谢。

StrLen() 函数检索字符串中的字符数。

<^<!-::
    InputBox, Text1, Count, Paste the text in the text box to count the number of characters it has, and find things in that text
    if ErrorLevel
        return
    number_of_chars := StrLen(Text1)
    MsgBox text:You typed %Text1%.`nCharacters:%number_of_chars%
return