Branch wise PO nos

souravbsouravb Member Posts: 135
Hi,
I have created separate PO numbers for 8 branches. Now the requirement is one branch user will be able to view the details of his branch only when he navigates the PO form. I have wirten the following code in On Open Form


IF GVUserSetup.GET(USERID) THEN
IF NOT GVUserSetup."View All Branch" THEN
SETFILTER("Shortcut Dimension 1 Code","Shortcut Dimension 1 Code");

and in On New Record


GVUserSetup.RESET;
GVUserSetup.SETRANGE("User ID",USERID);
GVUserSetup.FIND('-');
VALIDATE("Shortcut Dimension 1 Code",GVUserSetup."Shortcut Dimension 1 Code");

The problem is the user of a branch can still see other branch PO.
Plz help

"View all Branch" is a boolean field and the person having the permission will view all branch. The Shortcut Dimension 1 code is Branch.

Comments

  • ara3nara3n Member Posts: 9,256
    Standard Navision has this functionality called "Responsibility Center"
    You assign users to Responsibility center.
    It does what you are trying to do.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
  • ssinglassingla Member Posts: 2,973
    You can also see the multilocational voucher number series functionality in HF6.
    CA Sandeep Singla
    http://ssdynamics.co.in
  • ssinglassingla Member Posts: 2,973
    You can also see the multilocational voucher number series functionality in HF6 along with the Responsibility Centre setup as suggested by ara3n.
    CA Sandeep Singla
    http://ssdynamics.co.in
Sign In or Register to comment.