Check the current Company

curecure Member Posts: 77
Hello everybody

How do I know, on witch company I'm working actually? We have a customer, working with more then 300 Companies. Sometimes it can be useful to know, on witch company the User is working.

Is there any C/AL code to check that

Like: CurrComp := GiveMeCompanyName(); :lol:

Thanks for any help

bye bye, curdin

Comments

  • willywilly Member Posts: 67
    Hi! Try this:

    CurrComp := COMPANYNAME; (where CurrComp is your local variabel).
  • curecure Member Posts: 77
    Hey dude, thank you very much. This works great.

    Is this one of the undocumented function from NAV????

    How do I learn something about functions like COMPANYNAME?

    curdin
  • willywilly Member Posts: 67
    Hi!
    You will see the function if you go into C/AL symbol meny. Choose Database in the left colum and you will find it.

    Try this "Quick Reference" overview :
    http://www.mibuso.com/dlinfo.asp?FileID=855
  • curecure Member Posts: 77
    Thank you, this QUICKGUIDE looks really good.

    regards
    curdin
Sign In or Register to comment.