Hello Everyone
For some reason sometimes i filter Sales Order to display just orders created by USERID(user id loged in-).
And sometimes i don't want to filter Sales Order form(this is depended on one field boolean that is added to User Setup table).
If this field("Show all" sales order) = TRUE than show all orders, and if this field is false than filter just created by this Assing User ID =USERID(user id loged on).
The problem is that this is not working, when i check or uncheck this field "Show all".
The code is like this:
I have write this code on triggers Form - OnOpenForm() and From - OnAfterGetRecord().
IF UserSetup.GET(USERID) THEN
IF UserSetup."See All Orders" THEN
EXIT
ELSE
BEGIN
SETRANGE("Assigned User ID",USERID);
END;
Any suggestions, where is wrong.
Thanks,
0
Answers
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
But now i have tested it on From - OnAfterGetRecord() and tested even onOpenform and onaftergetrecord.
I have tested on this because if user pres F5 and pres the button Show all, it can see all orders.
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
Thanks for your help mohana_cse06
\:D/