PatternValue Question

SyntaxEditor for Windows Forms Forum

Posted 16 years ago by Shawn Nanto
Version: 4.0.0274
In my custom language the "@" symbol represents a Database Field. It can be expressed as @FieldName or @[Field Name With Spaces].

In my XML is the following token definition:

<RegexPatternGroup TokenKey="FieldToken" Style="FieldStyle" PatternValue="@ {WordMacro}+" LookAhead="{NonWordMacro}|\z" />

Currently the @FieldName is formatted correctly, and identified correctly as a FieldToken, but @[Field Name With Spaces] is not identified correctly.

How should I change the Pattern Value to also allow @[*]?


Shawn Nanto

Comments (1)

Posted 16 years ago by Actipro Software Support - Cleveland, OH, USA
Hi Shawn,

You can just make a second pattern group with the same TokenKey and Style but use a pattern that allows your alternate syntax. This way either one will be valid and will appear the same if you parse tokens later.

Actipro Software Support

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

Add Comment

Please log in to a validated account to post comments.