I have a form that allows for a manual change (one by one) of a checkbox (within a matrix). I would like to use the Find and Replace to Find, say all Yes’s that I have filtered in this list, and replace them with No’s. But Navision never allows for that to be done, as the Replace function is greyed out, and each have to be changed manually. Is there a way to do this? Or do we have to create a seperate function to update these?
Hi Torolf, I came across the same problem and the only way I was able to solve it was to write a little “two-line” processing-only report to update the respective data. Depending on your license you might be able to solve it yourself or your NSC might need to give you a hand… The report includes the concerned table as dataitem, you select the necessary filters running the report and in the OnAfterGetRecord you have CheckBoxField := FALSE; …(or TRUE) MODIFY; That’s it. Saludos Nils
I think Nils is correct. The only place I’ve seen Replace work in Navision is within the Object Designer. Not too useful for end users. Dave Studebaker das@libertyforever.com Liberty Grove Software A Navision Services Partner Edited by - daves on 2002 Feb 05 21:38:35
Thanks for the help. With a little fiddling, I was able to get it to work adequately. Another quick question. Is there a way to update the matrix, so that when the user goes back they can see that it actually worked? Right now, if you were to either exit out of the form or click each item in the matrix list, it will update, but not without this assistance. I tried to run the line of code on the form that invokes this function as: CurrForm.UPDATE(TRUE) but did not have any luck.
quote:
Originally posted by daves: The only place I’ve seen Replace work in Navision is within the Object Designer. Not too useful for end users.
Replace works if you want to replace text or code fields in the way Torolf was doing it (filter certain recs and change the data), but it does not work for checkboxes, I did not try it with option fields.
quote:
Is there a way to update the matrix,
Did you include the CurrReport.UPDATE(TRUE); in the OnAfterValidate of that specific field? Otherwise you might try CurrReport.NameMAtrixForm.UPDATE(TRUE); Saludos Nils Edited by - nilsm on 2002 Feb 06 00:25:41
I just tested and it works with Options fields. Dave Studebaker das@libertyforever.com Liberty Grove Software A Navision Services Partner
…so they just “forgot” to include replacing the value of checkboxes… though it’s not really an important feature… Thanks for the hint, Dave. Nils