如何在 vb.net 中对 TextBox 进行拼写检查以键入文本?

发布于 2024-08-05 23:53:41 字数 419 浏览 1 评论 0原文

我将尝试以下代码的方式:

'Click on Button1 spell checks Text1 textbox
Dim strResultText As String
Dim sc As New SpellChecker
sc.OpenDictionary "c:\SpellUS.lex"
Private Sub Button1_Click()
    TextBox1.Focus()

    strResultText = sc.CheckText(TextBox1.Text, ExitStatus)
    TextBox1.Text = strResultText
End Sub

但是上面的代码是错误的。 1. 拼写检查器 2.ExitStatus

我可以识别错误。但我不知道。如何修复错误?所以有人知道这个问题请帮忙。

I will try the way of the following code:

'Click on Button1 spell checks Text1 textbox
Dim strResultText As String
Dim sc As New SpellChecker
sc.OpenDictionary "c:\SpellUS.lex"
Private Sub Button1_Click()
    TextBox1.Focus()

    strResultText = sc.CheckText(TextBox1.Text, ExitStatus)
    TextBox1.Text = strResultText
End Sub

But The above code is error.
1. SpellChecker
2.ExitStatus

I can identify the error.But I don't know.How do fix the error?.So anybody know the problem please help.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

嘿咻 2024-08-12 23:53:41

我想检查 ExitStatus 会给你一个关于错误的线索(如果有的话)

I would imagine checking the ExitStatus would give you a clue about the error (if there is one that is)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文