However is possible delete an Variant Code from an Item if them has Inventory <>0.
Which Function can I Call or Modify so before Delete, it checks if they are Inventory <>0 and if Are Items with Variants in Order or in other Use ?
Thanks.
(Oo)=*=(oO)
0
Comments
rec32.RESET;
rec32.SETCURRENTKEY("Item No.","Variant Code");
rec32.SETRANGE("Item No.",'My Item No.');
rec32.SETRANGE("Variant Code",'My Variant Code');
rec32.CALCSUMS(Quantity);
IF rec32.Quantity <> 0 THEN
MESSAGE('Quantity is not 0');
If there is a quantity different from 0, you have to make item-postings to bring it to 0.
rec37.RESET;
rec37.SETCURRENTKEY(Type,"No.","Variant Code");
rec37.SETRANGE(Type,rec37.Type::Item);
rec37.SETRANGE("No.",'My Item No.');
rec37.SETRANGE("Variant Code",'My Variant Code');
IF rec37.FIND('-') THEN
MESSAGE('There are %1 records in table 37',rec37.COUNT);
and the same test for table 39.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
I'm checking at time if i can use it...
Well , i have now Code myself ... the solution with the form 342 and CU 311 likes Nice, but its me at moment to complicated modify / add any source
8-[
Thanks for you answer and tipp