Quantcast
Channel: Dynamics 365 Business Central/NAV User Group
Viewing all articles
Browse latest Browse all 11285

Forum Post: RE: Is there away to only allow one instance of Nav 2016 to launch?

$
0
0
Hello, BKR2016A. I have found this solution. ----------------------------------------------------------------------- For Restricting multiple Login we can use Codeunit 40 - LogInManagement. So let's see how we can achieve this - 1. Design Codeunit 40, Navigate to Function CompanyOpen(). 2. Append Below Lines as below - Before --------------------------------------------------- IF GUIALLOWED THEN LogInStart; --------------------------------------------------- After --------------------------------------------------- //>>Saurav.NAVBlog ActiveSession.SETRANGE("User ID",USERID); ActiveSession.SETRANGE("Client Type",ActiveSession."Client Type"::"Windows Client"); IF ActiveSession.COUNT > 1 THEN ERROR('You are Already Logined'); //<<Saurav.NAVBlog IF GUIALLOWED THEN LogInStart; --------------------------------------------------- Where - ActiveSession is of type Record Active Session best regards,

Viewing all articles
Browse latest Browse all 11285

Trending Articles