There are some common datatypes e.g. for records and fields - RecordRef and FieldRef. Yes they work pretty good.
But what can you do with Pages and the other Kinds objects e.g. Reports, ...?
I suggest to define a Interface in as a new object. Interfaces could be assigned by a property e.q.:
interface 50100 "My Interface"
{
procedure DoSomething(...)
begin
// no Code allowed
end;
}
page 50100 MyPage
{
// …
Interfaces = Interface::"My First Interface", Interface::"My Second Interface";
// …
// This Object must implement the interface method (local or global)
procedure DoSomething(...)
begin
// no Code allowed
end;
}
The generating of this Code / Objects in the NST with C# / .NET IL is not so difficult.
How to use such interface objects - the Variant DataType must be improved with several Methods:
var varInterface: Variant;
var myInterface: Interface::"My Interface";
if varInterface.IsInterface(Interface::"My Interface") then
begin
myInterface := varInterface;
myInterface.DoSomething(…);
end;
What do you think About my sugestion?
I fully support this because I and my colleagues so often face "generic" problems and push Nav to its limits. I thought the topic had already discuss here and there, but I only found the #111.
This is something we are already thinking about. I will mark this as a suggestion and provide updates once we get to this feature.
Most helpful comment
This is something we are already thinking about. I will mark this as a suggestion and provide updates once we get to this feature.