Options

Post Transfer order by specific user

Hi,
We have a customized requirement to specify which user can post Transfer order ship and receive. We have added 2 checboxes 'Transfer Ship' and 'Transfer Receive' in User Setup.

Then we added below code in CodeUnit 5706:

l_recUserSetup.GET(USERID);
IF l_recUserSetup."Transfer Ship" THEN
l_txtPostOptions := '&Ship';

IF l_recUserSetup."Transfer Receive" THEN
l_txtPostOptions := '&Receive';


l_recUserSetup point to User Setup table while l_txtPostOptions is a text variable.

and change below code:
//Selection := STRMENU(Text000,DefaultNumber);
Selection := STRMENU(l_txtPostOptions,DefaultNumber);


It is fine to post ship if only enable 'Transfer Ship' checkbox. However it prompt nothing to post when we only enable 'Transfer Receive' checkbox. If we checked both 'Transfer Ship' and 'Transfer Receive' then it is ok to post receive.

We are using NAV 2015 version.

Thanks very much!

Answers

  • Options
    byebye123456byebye123456 Member Posts: 2
    Hi,
    This issue is solved. I change the code to

    IF l_recUserSetup."Transfer Receive" THEN
    l_txtPostOptions += ',&Receive';

    As the STARMENU should include 2 options and Default Number is defined by some conditions in standard code.
Sign In or Register to comment.