Using SetFilter with a variable string

jkeoghjkeogh Member Posts: 5
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).

Answers

Sign In or Register to comment.