Hello All,
Right now, am trying to Disable a page if the user changed the Status as "Completed", then it should disable for all the users except one User group. If the status was completed, then if any of the users enter to the particular page, it should display who has changed the status and when it was completed.
Now, first part i was completed. Means while changing the Status the page is disabling, But the issue facing is
a) lines of items and Header menus are not disabled for that particular page and if we click on next and coming back at that time sometimes its not disabling.
b) Name and time Label of the status changed was not getting.
Kindly requesting your valuable suggestion which i will get desired output

pageextension 62001 "Jobs PageDisable" extends "Job Card"
{
trigger OnOpenPage();
var
UserGroupMember: Record "User Group Member";
begin
If Rec.Completed then begin
IF not UserGroupMember.Get('ADMIN', UserSecurityId(), CompanyName) then begin
CurrPage.Editable := false;
end
else
CurrPage.Editable := true;
end;
end;
trigger OnValidate();
var
myInt: Integer;
Confirm: Label 'The Job No :%1 Has been Closed by the User : %2 On Date %3.';
begin
If Rec.Completed then begin
IF not UserGroupMember.Get('ADMIN', UserSecurityId(), CompanyName) then begin
If Dialog.Confirm(StrSubstNo(Confirm,Rec."No.", Rec.SystemModifiedBy, Rec."Last Date Modified"), false) then begin
CurrPage.Update();
end
end;
end;
}