Hi,In my application (.NET Advantage 11.1) I have two UltraFormattedTextEditor that I want to have vertical scrollbar syncronized.I can see no event to catch the scrolling of the text or programmatically set the value of the scrollbar position.Can you help me please?ThanksStefano
Hi Stefano,
Could you please take a look at that forum thread http://forums.infragistics.com/forums/t/62365.aspx . There are attached sample with similar behavior. Please if you have any questions, do not hesitate to write me
Regards
Hi Georgi and thank you for the reply.
I checked out the thread and downloaded the sample, it works fine but I have to find a way to syncronize at least the vertical scrolling (best wuold be vertical and horizontal). I tried to put some twaeks to the sample but I couldn't find a good solution. May you can help me.
Thanks
Stefano
Hi Georgi,
your sample solution works fine, but there is one problem: if I scroll the left textEditor, the right one scrolls too, but it doesn't show the text and "ultraFormattedTextEditor.Refresh();" is not sufficient to do it. To make it easer to verify, I just modified your sample enlarging the textEditors and adding some text. Thank you for your support.
Hello Stefano,
Maybe you could try to use PerformAction method. For example:
private void ultraFormattedTextEditor1_VScroll(object sender, ScrollEventArgs scrollEventArgs) { ultraFormattedTextEditor2.PerformAction(FormattedLinkEditorAction.Down, false, false); } private void ultraFormattedTextEditor2_VScroll(object sender, ScrollEventArgs scrollEventArgs) { ultraFormattedTextEditor1.PerformAction(FormattedLinkEditorAction.Down, false, false); }
private void ultraFormattedTextEditor1_VScroll(object sender, ScrollEventArgs scrollEventArgs)
{
ultraFormattedTextEditor2.PerformAction(FormattedLinkEditorAction.Down, false, false);
}
private void ultraFormattedTextEditor2_VScroll(object sender, ScrollEventArgs scrollEventArgs)
ultraFormattedTextEditor1.PerformAction(FormattedLinkEditorAction.Down, false, false);
Please let me know if you have any questions
Hi Georgi,I may give up on using UltraFormattedTextEditor this time, I found an acceptable solution using classic RichTextBox and Win API.However, Thank you for your time.RegardsStefano
Thanks for your response, but please note that our UltraFormattedTextEditor has a lot a features that missing in the RichTextBox. More information about UltraFormattedTextEditor you could find at
http://help.infragistics.com/Help/NetAdvantage/WinForms/2011.2/CLR2.0/html/WinFormattedTextEditor_Support_Dialogs.html
http://help.infragistics.com/Help/NetAdvantage/WinForms/2011.2/CLR2.0/html/WinFormattedTextEditor.html
If you have any questions, do not hesiate to write me
Hi Georgi,I attached to this post a sample to show you how I got the sync scrolling using two RichTextBoxes and, as you can see in the project, the same code doesn't work with UltraFormattedTextEditors. I couldn't find a solution, but maybe you can find a way to make it work.ThanksStefano