Allow user to ship only

lamis
Member Posts: 46
Dears,
how can I prevent a user from (ship and invoice) and (invoice) while posting a sales invoice? I just want to let this user (ship) only.
Regards,
how can I prevent a user from (ship and invoice) and (invoice) while posting a sales invoice? I just want to let this user (ship) only.
Regards,
0
Answers
-
go to codeunit 81, there you will find this code
Selection := STRMENU(Text000,3);
IF Selection = 0 THEN
EXIT;
//ADD THIS CODE
IF Selection = 3 OR Selection = 2 THEN
ERROR(Not Allowed)
//ADD THIS CODE
Ship := Selection IN [1,3];
Invoice := Selection IN [2,3];
Thanks
Blog - rockwithnav.wordpress.com/
Twitter - https://twitter.com/RockwithNav
Facebook - https://facebook.com/rockwithnav/0 -
Hi,
Can adjust the code in CU 81 like below,
Declare Text Constant variable Text003 = &Ship
//Selection := STRMENU(Text000,3);
Selection := STRMENU(Text003,1);
IF Selection = 0 THEN
EXIT;
Ship := Selection IN [1,1];
//Invoice := Selection IN [2,3];
Then user can have access and visible to "Ship" option only.
0 -
This will be applied to all users, I just want to restrict one user only. Is that possible?0
-
Yes, it is possible to restrict particular user, but need to do some customization in code and table level
we can achieve like below(there may be more other scenarios to customize)
1. Add a field in table 91 "Onlyship" as boolean and Add the user in user setup, Mark "Onlyship".
2. Now adjust the code in Code unit - 81
Declared Table - 91 (user setup) as global variable with name "gRecUserSetup"
Declared Text Constant Text003 = &Ship
customize the code like below in CU-81
then we can prevent the user to access the other options.
0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions