if you run the “posted sales invoice” report in preview, you cannot print it anymore (“This list cannot be printed in preview …”), unless you close the preview and print it immediately. I cannot find where this property is set. Anyone with an idea ?
Hi, Took me a long time to find the first time: look for something like IF CurrReport.PREVIEW THEN in the report code. If PREVIEW is used somewhere the report will automatically prohibit printing from the preview.
Hello Guy, As mvagh says, look for the CurrReport.PREVIEW in the report. It is important to understand why you cannot print certain reports (Like the invoice) from print preview. This is becuase they write back to Navision when they are printed, for example, the “No. Printed” field. The problem is that if you were allowed to print from print preview, then they would not update Navision becuase they have already been “run” and the fields would not be updated (No. Printed would never increment). It is not a good idea to take the CurrReport.PREVIEW warning out becuase the reports will no longer update your database [B)] … It is best to leave this in place.
Ah, well you learn something new every day. Always wondered why this was and blamed it on the client software not being up to the job. Thanks for the insight. Regards Meint
Thanks for the info. I wasn’t going to change the posted invoice report, but was searching for the way to have this functionality in a new report. I’m glad Navision is smart enough to prevent printing starting from the preview when it detects that there is a test on it ni C/AL.