Hello, don't know if I am right here but anyway:
I don't get it how to call an action/procedure from withhin the OnValidate() function inside a field - to simple to get it.
The exercise is to:
-
Call the procedure GetSuggestion from within the OnValidate trigger.
Code blow:
page 50112 StatmentsCard
{
PageType = Card;
ApplicationArea = All;
UsageCategory = Documents;
Caption = 'Statments Card';
layout
{
area(Content)
{
group(Eingabe)
{
Caption = 'Input';
Description = 'Input';
field(Schwierigkeitsgrad; Difficulty) //tpagefield
{
ApplicationArea = All;
Description = 'Schwierigkeitsgrad';
trigger OnValidate()
begin
end;
}
}
group(Ausgabe)
{
caption = 'Output';
field(Vorschlag; Suggestion)
{
ApplicationArea = All;
Description = 'Vorschlag';
Editable = false;
}
field(Ebene; Level)
{
ApplicationArea = All;
Description = 'Ebene';
Editable = false;
}
}
}
}
actions
{
area(Processing)
{
action(GetSuggestion)
{
ApplicationArea = All;
trigger OnAction()
begin
Level := '';
Suggestion := '';
case Difficulty of
1 .. 5:
begin
Level := 'Beginner';
Suggestion := 'Take e-Learning or remote training';
end;
6 .. 8:
begin
Level := 'Intermediate';
Suggestion := 'Attend instructor-Led';
end;
9 .. 10:
begin
Level := 'Advanced';
Suggestion := 'Attend instructor-Led and self study';
end;
end;
end;
}
}
}
var
Level: Text[30];
Suggestion: Text[80];
Difficulty: Integer;
}
Thank you,
Tom

Report
All responses (
Answers (