AutoReplacements Broke (Kinda)

SyntaxEditor for Windows Forms Forum

Posted 20 years ago by painetraine
Avatar
I have a bunch of autoreplacements defined for my application and they all begin with !. So a replacement may be !fn and that is replaced with FileName or something.

However, with the v2.0.3 version, autoreplacements no longer work and the ! seems to be the breaking character because if I define an autoreplacement without the ! then everything works ok.

As an example if you modify the mainform constructor of the sample app (C#) to the following

// Force the C# language to load by default
// fileAutoLoadLanguageExampleTextMenuItem.Checked = false;
languageCSharpMenuItem.PerformClick();
this.editor.Language.AutoReplace.Add(new AutoReplaceEntry("!fn", "sql.txt"));

Using v2.0.102 the autoreplacement will work, using v2.0.103, the autoreplacement will not work.

I have modified my code to remove the ! when adding the replacement to the collection and then remove it when the auto replacement is performed, but is there another way for me to handle this?

Thanls

Comments (1)

Posted 20 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hmm... auto-replace wasn't working correctly in the first 2.0 versions because it would allow the ends of words to be replaced (which shouldn't happen, only the whole word) so we had changed that in the latest build. But our change must have broken your situation. We'll try to get this fixed as soon as possible.


Actipro Software Support

The latest build of this product (v24.1.0) was released 2 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.