Solved

SpellChecker problem in RichTextBox in WPF in VS 2008

Posted on 2007-11-23
4
906 Views
Last Modified: 2013-11-26
I am trying to activate the spellchecking of a RichTextBox control but nothing happens.

I have tried (and double checked) the <RichTextBox SpellCheck.IsEnabled="True"/>, but nothing happens.

I have also downloaded 3 different demo projects that all demostrate the use of the new RichTextBox. All project builds and works perfectly, except for the spellchecker function which is totally silent. I have also tried to change the language using the attribute for this (since the OS language is Norwegian), but it does not help. Is the cause for this kind of problem known? Is the problem the OS language settings?

I am using VS 2005 with "VS 2008 addon" which seems to be working since I am able to open VS 2008 projects using the "selector".
0
Comment
Question by:lieka
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 96

Expert Comment

by:Bob Learned
ID: 20354502
If you have something like this, it should highlight the mispelled words.
    <DockPanel xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" Margin='8px'>
        <TextBlock DockPanel.Dock='Top' HorizontalAlignment='Center' FontSize='14pt' FontWeight='Bold'>Windows Presentation Foundation Spell Checker</TextBlock>
        <RichTextBox SpellCheck.IsEnabled='True'>
            <FlowDocument>
                <Paragraph Foreground='#17365D' Background='White' FontSize='12pt' FontFamily='Cambria'>Enter your text here to have it spell-checked. Like soo.</Paragraph>
            </FlowDocument>
        </RichTextBox>
    </DockPanel>

Open in new window

0
 
LVL 96

Expert Comment

by:Bob Learned
ID: 20354505
0
 

Author Comment

by:lieka
ID: 20361574
Thanks! Finally there was a red line indicating a typo. But - the spellchecker is only concerned about the text added as the paragraph: <Paragraph ......>Enter your text here to have it spell-checked. Like soo.</Paragraph>
Wrongly spelled words ('soo') are indicated, but words added to the controll by editing are not spellchecked. Interestingly, words from the original sentence which are messed up by me inserting text into them are highlighted, but the random/nonsense text inserted into them are not higlighted.
Example: If I change "Enter your text here" to "Enter your te xt xt here" the 'te' and the second 'xt' becomes highlighted, while the inserted/first 'xt' is ignored by the spellchecker.

Should I invoke the spellcheck procedure as a response to any kind of event of the RichTextBox-control?
0
 
LVL 96

Accepted Solution

by:
Bob Learned earned 500 total points
ID: 20362856
It appears that English is supported with the WPF, when typing in the RichTextBox, but I don't know what other languages are supported.

Bob
0

Featured Post

Is Your Team Achieving Their Full Potential?

74% of employees feel they are not achieving their full potential. With Linux Academy, not only will you strengthen your team's core competencies but also their knowledge of of the newest IT topics.

With new material every week, we'll make sure that you stay ahead of the game.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question