User Defined Language: what do I do wrong ?
-
I set Power Query “M Language” as User Defined Language according to https://ssbi-blog.de/blog/technical-topics-english/power-query-editor-using-notepad/ and https://www.excelforum.com/tips-and-tutorials/1230126-how-to-create-an-editor-for-power-query-with-notepad-thanks-matt-masson.html, and Syntax Highlighting works, but I have 2 questions:
- I don’t have "intellisense"working or don’t know how to use
- The “M Language” doesn’t show up at the M in the Language menu, but somewhere in the bottom of that menu:
"
So I think I did something wronge, but can’t find it. It work for my most important part, so I can live with it, but this keeps annoying me.
Has anyone experience with UDL’s and can you help me with this issue?
Kind regards, Hans
-
-
Your links are broken, so until you fix them, nobody can really know what you mean by “intellisense”.
If by “intellisense” you mean something along the lines of seeing a drop-down list of possible methods for an object appearing magically OR getting automatic highlighting of syntax errors based on a deep understanding of M language’s syntax, that is not the sort of thing that Notepad++ can do by default, although it may be possible to create a plugin to do that sort of thing.
If by “intellisense” you mean something very limited like Notepad++ has an autocompletion list of keywords for the language but no understanding of which situations they would make sense in, that is something you can probably do, though I’m not sure exactly how.
-
@Hans-Troost ,
M, is right where it belongs. Under the label of User Defined Language. In the alphabetical listings, those are reserved for the internally recognized language recognitions that comes with the Notepad++ application.Any language that isn’t native to Notepad++, (that you make) is listed right where it is. Nothing is wrong. Everything is right.
-
Further to what @Mark-Olson said,
If by “intellisense” you mean something very limited like Notepad++ has an autocompletion list of keywords for the language but no understanding of which situations they would make sense in, that is something you can probably do, though I’m not sure exactly how.
The process of creating that file - whether it’s editing one for the built-in languages or creating a new one for a User Defined Language (UDL) like the M Language that you mentioned – is described in the Online User Manual in the Auto-completion > Create auto-completion definition files.
-
My apologies for not reacting to you up to now: I think I did not configure my email-notification correct and I was waiting for email notifications. Sorry, sorry…
I just now thought: “hey, I didn’t hear (read) any replies, let’s have a look.”.
So here is my reply to you all:Thanks a lot for seriously looking to my question and replying, I really appreciate it.
Regarding the content:
- I understand what you all are writing: Notepad++ doesn’t understand the UDL language but in the 1st reference the word Intellisense is mentioned but better reading: the implementation is less than that, but at least “Autocomplete”. I will try that again, after this better reading.
2nd Question: about the position of the M Language (the UDL) in the menu. Is’nt that strange? Anyone of you an idea? Of course I can live with it, I’m just surprised with this behavior.
Thanks in advance and best regards,
Hans Troost -
@Hans-Troost said in User Defined Language: what do I do wrong ?:
My apologies for not reacting to you up to now: I think I did not configure my email-notification correct and I was waiting for email notifications. Sorry, sorry…
This forum software rarely correctly handles email notifications, even if you think you have them turned on. It’s best just to come back and check for yourself.
but in the 1st reference the word Intellisense is mentioned but better reading: the implementation is less than that, but at least “Autocomplete”. I will try that again, after this better reading.
We in the Notepad++ Community Forum have no control over a blog written on some other site; if they are providing misinformation about Notepad++, there’s nothing we can do there. “IntelliSense” is Microsoft’s implementation of “intelligent code completion”, and that trademark is owned by Microsoft. No other company is allowed to use that term for their own product (and any that do are likely to get a trademark infringement lawsuit), and any blogger who uses it as a generic term for auto-completion or even for intelligent code completion has misunderstood what “IntelliSense” is.
Notepad++ only does auto-completion, it doesn’t have “intelligent code completion” by default (though there are plugins that are being slowly developed which will hopefully allow Notepad++ to connect to LSP servers, which may eventually enable more intelligent code completion). So for now, you have to follow the instructions I linked in order to manually set up a Notepad++ auto-completion file for your M UDL.
2nd Question: about the position of the M Language (the UDL) in the menu. Is’nt that strange? Anyone of you an idea? Of course I can live with it, I’m just surprised with this behavior.
I thought that was pretty clearly answered above: no, it’s not strange. All the built-in languages go above the horizontal line in the menu, sorted alphabetically. All user-defined languages (UDL) go below the line. That way, you can tell whether the active language for your file is built-in (if it’s above the line) or a UDL (below the line). It’s done on purpose, and will not be changed.