I have a new field on the GL Account Table as follows.
Valid Departments. Code50 where the user will enter a string like '001..050' or '001|002|003' or 'A*|B*|C*' etc.
I want to use this value to limit the lookup on Dimensions Values so I was hoping the following line of code would work.
rDimensionValues.Setfilter(Code, '%1', rGL."Valid Department");
However this only work if something like 'A*' has been entered in the GL.ValidDepartments field, it won't work if there is a range or more than one value has been entered etc. In this case it'll just return an empty recordset.
I was wondering does anyone know of a quick solution.
Regards,
JK. (First post so apols if it is in wrong place).
0
Answers
FILTERGROUP := 2;
SETRANGE(Code,"valid departements");
FILTERGROUP := 0;
Try this code:
rDimensionValues.Setfilter(Code,rGL."Valid Department");
Thats perfect.
JK