Options

SETRANGE function on the page

ezeeze Member Posts: 3
Hi, guys, I have a problem with SETRANGE function usage on a page. I have added CurrentJobNo variable to Job Card page. It should work this way: when I choose a different CurrentJobNo(validate this field), Job Card page should be filtered to only show those Jobs that have Job No. equal to CurrentJobNo.

So the code looks like this:

CurrentJobNo - OnValidate()

SETRANGE("Job No.",CurrentJobNo);
MESSAGE(CurrentJobNo);
MESSAGE("Job No.");

I do not understand why it doesn't work. As you can see I have two messages for testing. So the first message shows the correct value(example J0005) that I want to filter on, but the second message shows the old value. Why does SETRANGE do not filter Job No. to this new value??

Best Answers

Answers

Sign In or Register to comment.