Completing the intellisense-enabled scripting experience #425
-
Hi, Authoring C# scripts in Visual Studio or VSCode referencing TOMWrapper.dll is great as we get complete intellisense "Selected" is maybe the most important one. How can we replicate an object with the same name that provides intellisense on the properties and methods of Selected? For Model we just created a variable of Model type named "Model" and it works nice, however not sure how to proceed with Selected Other hold-outs are the functions Info Error Output Thank you! I hope it makes sense |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Short term, I think you can get the IntelliSense you’re asking for by adding a reference to TabularEditor.exe (TE2).
Longer term, we plan to have full IntelliSense-like features in TE3 when writing C# scripts. |
Beta Was this translation helpful? Give feedback.
Short term, I think you can get the IntelliSense you’re asking for by adding a reference to TabularEditor.exe (TE2).
Selected
is an object of type TabularEditor.UI.UITreeSelection.Info
,Output
, etc.) are defined here, so addingusing TabularEditor.Scripting;
should at least allow you to use the extension methods. You can’t refer the methods directly (that is, without qualifying them withScriptHelper
or without using them as extension methods). This is only possible when the script is executed in TE because TE has a precompiler that transforms the script before sending it to the C# compiler, i.e. transformingInfo("Hello World");
toScriptHelper.Info("Hello World");
.…