Page 1 of 1

Suppress Line unless qty remaining to despatch

Posted: 05 Jul 2023, 09:05
by arsenalrule
Hi Bruce and all

I am editing the Sales Order Report, and looking to create a report that only shows lines that are waiting for despatch.
We use an external program (CIM50) to despatch our items - I am not sure if this affects things?

Originally I used 'SOP_ITEM.QTY_ORDER - SOP_ITEM.QTY_DELIVERED = 0.00', but this suppressed everything in the column.
I have tried entered conditional formating (SOP_ITEM.STOCK_CODE LIKE "M") and TRUE on suppress printing, but the whole column is suppressed, not just items with stock code M. I have also tried 'SOP_ITEM.QTY_ORDER = 20.00' as this particular order has 20qty of 2 items, and then qty's of 30,15,5,50 etc. so I thought this would only suppress 2 lines, but again it suppresses the whole column.

Do you have any idea what I am doing wrong?

Picture attached of the report, and the preview output from this.

Thanks

Re: Suppress Line unless qty remaining to despatch

Posted: 05 Jul 2023, 15:01
by brucedenney
Is "LIKE" a valid operator?
Perhaps you could attach the layout to your post as it may be something else.

As a general rule, when "debugging" reports it is useful to create an expression on the page which you can see the result of and be sure you are getting the values you expect.

SOP_ITEM.QTY_ORDER - SOP_ITEM.QTY_DELIVERED = 0.00 seems perfect to me, i suspect that it is something subtle.

Re: Suppress Line unless qty remaining to despatch

Posted: 06 Jul 2023, 07:54
by arsenalrule
Thanks Bruce

The LIKE "M" was from the Sage webpage on how to use conditional formatting!

Please find the .layout atatched. I have SOP_ITEM.QTY_ORDER - SOP_ITEM.QTY_DELIVERED as the first column, and it shows nothing for all rows, except the row that still needs 3 items despatching.
This is then in the conditional formatting, with suppress priting, but suppresses the whole column still.

is it becuase SOP_ITEM.QTY_ORDER - SOP_ITEM.QTY_DELIVERED doesnt = 0?

Thanks
Steve

Re: Suppress Line unless qty remaining to despatch

Posted: 11 Jul 2023, 10:17
by arsenalrule
Hi Bruce

Did you have any luck looking at this?

Thanks

Re: Suppress Line unless qty remaining to despatch

Posted: 11 Jul 2023, 11:12
by brucedenney
Sorry very busy, I can't turn customers away to give free help on the forum.

Re: Suppress Line unless qty remaining to despatch

Posted: 11 Jul 2023, 15:28
by brucedenney
I have had a look.

I gave the expression on the left of the Item_Number Section the name "Outstanding" having an expression without a name is not a good idea.

I switched off advanced conditional formatting, not sure why you were trying to use it. I think the conditional formatting may have been setting suppress print to true, but it was already set to true so nothing printed either way.

I removed all the conditional formatting from all items in the section

I set all items to have suppress print set to false as they were set to be hidden by default

I changed the filter on the section to be "SOP_ITEM.SERVICE_FLAG = 0 AND Outstanding > 0" so only items that have an outstanding qty will print.

The way you were trying to do it, even if you had been successful, you would have got blank lines wherever there was a line that had been completed. With my approach the line is only printed if there is an outstanding item, there is no conditional formatting at all.

“If the only tool you have is a hammer, you tend to see every problem as a nail.” - Abraham Maslow

Attached is my reworking, hopefully you can see how it works and it makes sense to you
ERROR Suppress not working BD.layout

Re: Suppress Line unless qty remaining to despatch

Posted: 12 Jul 2023, 08:56
by arsenalrule
Thats amazing, thank you Bruce

I think I had tried so many different things, that I forgot to undo lots of them!

I have now made these changes to my report and it is working as expected.

Thank you