take off a record in a form

I need to know which function or C/AL procedure makes desappear a record from a form, after changing a field status:

I have a form where, after change a field status on one record, this recod desapear from my form, after that change.

How that happen?

Thanks

Hi Luana,

use SETFILTER or SETRANGE and a CURRFORM.UPDATE

Hi Dave

In my form I have:

Form - OnFindRecord(Which : Text[1024]) : Boolean
IF FIND(Which) THEN
EXIT(TRUE)
ELSE BEGIN
SETRANGE(“No.”);
EXIT(FIND(Which));
END;

Form - OnAfterGetRecord()
SETRANGE(“No.”);

I whant to make the shange in my field and mantain the record in my form. Now, when I change my record he is taked of my front. How avoid it?

Hi,

If I understand - You want the user to enter into the “No.” field and then find this record to amend. This is not standard Nav method and should be discouraged.

If this is not the case, can you please give a more detailed description - a screenshot would help

Hi Dave

No. The situation is:

The user enter into the Service Header.“No.”, makes a change in a field , for example the status of a SErvice Order, and then, the form take off automatically this record from the form list, and the same form returns another “No.”. I want avoid this. I want user change that field but continues seeing the record in form list.

My question is: How that happen? Where is the CAL code that is doing this?

Hi,

This sound like you are filtering on the Status and when you update the status the form refreshes the list and excludes the Service Header. Look at the filters set on the form. If this is not an option you will need to look at coding around it.