Hi Everybody
I am generating a report where i am calculating item wise total output and total sale and i want to hide the item where total output and total sale is 0 so please guide me up how can i hide those item where the values are coming 0.
Ex:
Item: Total Output Total Sale
Item1: 54 4
Item2: 0 0
Item3: 9 0
Item4: 0 5
Item5: 0 0
Item6: 0 0
Item7: 9 0
Considering above example i want to hide Item2 , Item 5, Item 6
0
Comments
it will display the section when both are not zero and hide section whenever both are zero.
On the Presection of the section you are showing put this code:
or you can put this code after your codes in the OnAfterGetRecord of your Data Item.
I tried this code but it is not helping me still showing all the lines
that
" Type Conversion is not possible as Integer and Decimal "
well itried these codes but still it's not helping me out. I mean still it is showing me all those lines with null values
Please put this code on presection trigger, it should work fine... \:D/
Actually, this one is work as same as easabangan's
So better would be (if you don't want the record to show and don't need it for anything else:
OnAfterRecord: But in this place:are you sure you use the correct variables to test for 0?
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
Still it is not solving my purpose sa,e thing is happening , it is showing all the lines
I am trying this but it is not helping me out
These codes surely works.
Item.SETRANGE(Item."Inventory Posting Group",Item."Inventory Posting Group"::FG);
ILE.SETRANGE(ILE."Item No.",Item."No.");
"Total Output":=0;
"Total Sale":=0;
ILE.SETFILTER(ILE."Posting Date",'>=%1',"Start Date");
ILE.SETFILTER(ILE."Posting Date",'<=%1',"End Date");
IF ILE.FIND('-') THEN BEGIN
REPEAT
IF ILE."Entry Type"=ILE."Entry Type"::Output THEN BEGIN
"Total Output":="Total Output"+ILE.Quantity;
END
ELSE IF ILE."Entry Type"=ILE."Entry Type"::Sale THEN BEGIN
"Total Sale":="Total Sale"+ILE.Quantity;
END;
UNTIL ILE.NEXT=0;
CurrReport.SHOWOUTPUT(("Total Output"<>0)AND ("Total Sale"<>0))
END;
this is my code
now tell me
Try to use this code
// In this place you should have 1 item (I don't know about the rest of the report, but if there is nothing else, I would make a dataItem on Table Item and put the code in the "OnAfterGetRecord" of the item-dataitem)
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
I am writing my codes using curreport property on pre section trigger and if i use at on after get record then then i am using skip function but no solution is made yet
http://www.waldo.be/modules.php?
http://www.abc-computers.com/downloads/downloads.htm
http://www.geocities.com/navision_attain/downloads.html