How to check max number of licensed users?

infonoteinfonote Posts: 233Member
Hi,

Does anyone know how I can check the max number of users allowed by the license?

Thanks

Comments

  • DaveTDaveT Posts: 1,039Member
    Hi,

    Have a look at the licence with Tool -> licence information. It is slightly different depending how old the licence, but look for the number of sessions
    Dave Treanor

    Dynamics Nav Add-ons
    http://www.simplydynamics.ie/Addons.html
  • garakgarak Posts: 3,263Member
    This info is stored in the licensefile. Nav reads here the license
    Do you make it right, it works too!
  • jversusjjversusj Posts: 489Member
    can't you also click File --> Database --> Information, then click 'Sessions' tab and read value of "Licensed Sessions" field?

    this may be easier for some end users...

    (of course, don't you have to subtract 2 licenses automatically for the server?)
    kind of fell into this...
  • garakgarak Posts: 3,263Member
    i think he need it via C/AL.
    If not, go to File -> Database -> Info -> Session (as jversusj said)
    Do you make it right, it works too!
  • jversusjjversusj Posts: 489Member
    garak wrote:
    i think he need it via C/AL.
    If not, go to File -> Database -> Info -> Session (as jversusj said)

    how would you get it via C/AL? would you have to call the License Information table and skip through lines until you got the line regarding the sessions? just curious...
    kind of fell into this...
  • garakgarak Posts: 3,263Member
    jversusj wrote:
    garak wrote:
    i think he need it via C/AL.
    If not, go to File -> Database -> Info -> Session (as jversusj said)

    how would you get it via C/AL? would you have to call the License Information table and skip through lines until you got the line regarding the sessions? just curious...


    i doesn't read it with C/AL because u can't do it (without breaching the fingers). These infos are stored in the license file self. NAV read it when you load the client and connect to a server. Wit native server the license file is in the server directory as fin.flf (how to connect there to the directory [permission problems]), with sql it's stored in the master database in a separate table as BLOB.
    Do you make it right, it works too!
  • DaveTDaveT Posts: 1,039Member
    garak wrote:
    i think he need it via C/AL.

    We can add being psychic to the long list of your talents :lol::lol:
    Dave Treanor

    Dynamics Nav Add-ons
    http://www.simplydynamics.ie/Addons.html
  • greensmilegreensmile Posts: 7Member
    Hi,
    it so easy, try this sample of code:
    VAR
    [email protected] : Record 2000000040
    [email protected]: Integer
    
    LicenceInf.SETFILTER(Text,'%1%2%3', '*',  '1,200', '*'); // granule id filter
    LicenceInf.FINDFIRST; // if error raised, probably developer licence
    EVALUATE(MaxUsers, DELCHR(COPYSTR(LicenceInf.Text,STRLEN(LicenceInf.Text) - 5), '<>'));
    MESSAGE('Max number of licensed users: %1', MaxUsers);
    
    8) & :whistle:
    _-========-_
    GreenSmile
  • gycsiakgycsiak Posts: 13Member
    I know, that this topic is for Classic Client, but to make sure, this information is RTC-ready, here is the working code for Dynamics NAV 2017:
    CLEAR(MaxUsers);
    CLEAR(LicenseInformation);
    CLEAR(ActiveSession);
    
    LicenseInformation.SETFILTER(Text,'%1', '*450*');
    IF LicenseInformation.FINDFIRST THEN REPEAT
          CLEAR(MaxUsersLineCount);
          EVALUATE(MaxUsersLineCount, DELCHR(COPYSTR(LicenseInformation.Text,STRLEN(LicenseInformation.Text) - 5), '<>'));
          MaxUsers += MaxUsersLineCount;
      UNTIL LicenseInformation.NEXT=0;
    
Sign In or Register to comment.