Is it possible to call functions in codeunits by another way then by name.
I want to create some functions to import data and I want to make a possibility to user to choose the "right" function (for example by number)
It is not possible out of the box. You can run a codeunit by referring the number but not functions in the codeunit.
However you can use the OnRun trigger to achieve you gold. Create a function that sets the function you want to run and use a Case statement on the OnRun trigger to control the function to run.
A much easier way to accomplish that (since you're hard coding it anyway) is to display a STRMENU to the user and use the returned value in the CASE statement.
Comments
However you can use the OnRun trigger to achieve you gold. Create a function that sets the function you want to run and use a Case statement on the OnRun trigger to control the function to run.
Regards
Claus
http://www.AcumenConsulting.co.nz
RIS Plus, LLC