Hi all...
I am using cloud BC and publish the page.
but sometimes upon modify (my case is Posting Date), there is a confirmation dialog.
in BC, I want it to be NO
but unfortunately there is no confirmation dialog if validate via API.
Are we able to set as No in API?
Thanks before.
Answers
You can try with the below code to skip changing the lines
[EventSubscriber(ObjectType::Table, Database::"Sales Header", 'OnBeforeUpdateSalesLinesByFieldNo', '', false, false)]
local procedure OnBeforeUpdateSalesLinesByFieldNo(var SalesHeader: Record "Sales Header"; ChangedFieldNo: Integer; var AskQuestion: Boolean; var IsHandled: Boolean; xSalesHeader: Record "Sales Header"; CurrentFieldNo: Integer);
var
SalesLine: Record "Sales Line";
begin
if ChangedFieldNo = SalesLine.FieldNo("Deferral Code") then
IsHandled := not GuiAllowed;
end;
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
thanks for your help.
by the way if we add this, does it also no confirmation dialog for normal user? (outside API)
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
Thank you so much @mohana_cse06