Intellisense auto complete when pressing Enter

SyntaxEditor .NET Languages Add-on for Windows Forms Forum

The latest build of this product (v22.1.3) was released 1 month ago, which was before this thread was created.
Posted 20 days ago by Gavin Huet
Version: 22.1.3
Avatar

Hi,

If I am typing and the autocomplete intellisense appears, is there a way to make the enter key do a line feed as opposed to just selecting what is in the autocomplete list?

Example, type in "Dim a As String", the autocomplete list appears, "String" is selected, so if I press enter all it does is close the autocomplete list, whereas I want it to do a line feed.

Many thanks

Gavin

Comments (1)

Answer - Posted 20 days ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hi Gavin,

If you make a class that inherits VBCompletionProvider and you override its OnSessionOpening method, add this line:

((CompletionSession)session).IsEnterKeyHandledOnCommit = false;

Then return the result of the base method implementation call.

Setting that property will allow Enter to insert a line feed.


Actipro Software Support

Add Comment

Please log in to a validated account to post comments.