Hi All,
I'm trying to create a New Page from a New table.
The issue im having is t hat the fields do not populate themselves.
I require the following
Item
Description
SKU
Bin Code
This is my Table
table 50111 "X_Item Report"
{
Caption = 'X_Item Report';
DataClassification = ToBeClassified;
fields
{
field(1; "Item No "; Text[100])
{
Caption = 'Item No ';
DataClassification = ToBeClassified;
TableRelation = Item."No.";
}
field(2; Description; Text[200])
{
Caption = 'Description';
DataClassification = ToBeClassified;
TableRelation = Item.Description where(Description = field("Item No "));
}
field(3; SKU; Code[50])
{
Caption = 'SKU';
DataClassification = ToBeClassified;
TableRelation = "Stockkeeping Unit"."Item No." where("Item No." = field("Item No "));
}
field(4; "Bin"; Text[100])
{
Caption = 'Bin of last occurance';
DataClassification = Tobeclassified;
TableRelation = "Bin Content"."Bin Code" where("Item No." = field("Item No "));
}
}
keys
{
key(PK; "Item No ")
{
Clustered = true;
}
}
}
I tried using a trigger, however it doesn't seem to be picking up the fields.
This is the trigger i tried using for the description
trigger OnValidate()
var
recDesc: Record "Item";
begin
if "Item No " = "Item No "
then
if recDesc.get("Description") then begin
"Description" := "Description"
end;
end;
Any assistance would be greatly appreciated