|
|||||||
| TX Text Control RapidSpell .NET Please use this forum for TX Text Control RapidSpell .NET support only. If you need support for a different product, please use the appropriate forum. |
![]() |
|
|
Thread Tools | Display Modes |
|
#1
|
|||
|
|||
|
Spell Check against multiple TXTextControls
I was attempting to upgrade from 13.0 -> 15.0 using the integrated version of RapidSpell rather than the version purchased directly from Keyoti. I have been able to get things to compile, but I cannot seem to get the spell checker to work across multiple controls. Our forms can have up to 8-10 TXTextControl instances on each form, thus there needs to be a method to check all controls with a single menu-click. I tried the following with no luck:
Code:
public override void SpellcheckAllControls()
{
// does not work -- AddTextComponent does not seem to work
//rsdSpellCheckAllControls.AddTextComponent(rteTitle);
//rsdSpellCheckAllControls.AddTextComponent(rteRatingChg);
//rsdSpellCheckAllControls.AddTextComponent(rteComments);
rsdSpellCheckAllControls.Check();
// only checks last misspelled word in last instance of controls (rteComments)
rsdSpellCheckAllControls.TextControl = rteTitle;
rsdSpellCheckAllControls.Check();
rsdSpellCheckAllControls.TextControl = rteRatingChg;
rsdSpellCheckAllControls.Check();
//rsdSpellCheckAllControls.AddTextComponent(rteComments);
rsdSpellCheckAllControls.TextControl = rteComments;
rsdSpellCheckAllControls.Check();
// pre-upgrade spellchecker code (used to be easy)
//rsdSpellCheckAllControls.ThirdPartyTextComponentToCheck = null;
//rsdSpellCheckAllControls.ThirdPartyTextComponentsToCheck = new Keyoti.RapidSpell.ISpellCheckableTextComponent[] { new TextBoxBaseWrapper(wbtRNTitle), txaRatingChg, txaComments };
//rsdSpellCheckAllControls.Check();
}
Thank you. Chris Last edited by Gunnar Giffey; July 28, 2009 at 15:41:01. Reason: Please use the BB CODE tag for code: http://forums.textcontrol.com/misc.php?do=bbcode#code |
|
#2
|
||||
|
||||
|
Re: Spell Check against multiple TXTextControls
Dear Chris,
I tried the first code and it works fine for me Code:
//rsdSpellCheckAllControls.AddTextComponent(rteTitle ); //rsdSpellCheckAllControls.AddTextComponent(rteRatin gChg); //rsdSpellCheckAllControls.AddTextComponent(rteComme nts); rsdSpellCheckAllControls.Check(); this is definitely the recommended way to do it. But, you tried this too Code:
rsdSpellCheckAllControls.TextControl = rteTitle; rsdSpellCheckAllControls.Check(); rsdSpellCheckAllControls.TextControl = rteRatingChg; rsdSpellCheckAllControls.Check(); Code:
RapidSpellDialog.Modal=true Regards, Fabian |
|
#3
|
|||
|
|||
|
Re: Spell Check against multiple TXTextControls
I attempted to use the code you suggested, see method below:
Code:
public override void SpellcheckAllControls()
{
rsdSpellCheckAllControls.AddTextComponent(rteTitle);
rsdSpellCheckAllControls.AddTextComponent(rteRatingChg);
rsdSpellCheckAllControls.AddTextComponent(rteComments);
rsdSpellCheckAllControls.Check();
}
Code:
System.Exception was unhandled by user code
Message="Cannot call RapidSpellDialog.Check() without setting a text box to check. See TextBoxBaseToCheck or ThirdPartyTextComponentToCheck properties."
Source="TXTextControl.RapidSpell.NET"
StackTrace:
at Keyoti.RapidSpell.TX.RapidSpellDialog.Check()
at WilliamBlair.IM.FrontOffice.IMDashboard.UI.Outlook.ResearchNote.SpellcheckAllControls() in C:\WilliamBlair\IM\FrontOffice\IMDashboard\Outlook\IMDashboard.UI.Outlook\ResearchNote.cs:line 1450
at WilliamBlair.IM.FrontOffice.IMDashboard.UI.Common.OLMainMenu.mnuSpelling_Click(Object sender, EventArgs e) in C:\WilliamBlair\IM\FrontOffice\IMDashboard\Outlook\IMDashboard.UI.Common\Controls\OLMainMenu.cs:line 683
at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
InnerException:
Any additional help would be extremely helpful. Thank you in advance for your reply. Chris |
|
#4
|
|||
|
|||
|
Re: Spell Check against multiple TXTextControls
Got the fix... I was not setting the TextControl at design time. Instead I was setting all of the controls to check during the call to the function. When I set the TextControl property = rteTitle at design time, then added the additional controls at runtime; the control works as planned. So... good to go, but not too intuitive.
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Problem while using Keyoti Rapid Spell Check with Text Control 14 | Deepakt | TX Text Control .NET | 1 | September 25, 2008 14:09:29 |
| Spell Check | Unregistered | TX Text Control ActiveX | 0 | June 7, 2003 17:41:16 |
| The .net spell check sample | Unregistered | TX Text Control .NET | 1 | January 16, 2003 13:49:28 |
| Spell Check in .net [TX .NET prerelease] | Unregistered | TX Text Control .NET | 2 | December 12, 2002 15:38:14 |