CLEAR(OldTempPaymentBuffer); TempPaymentBuffer.SETCURRENTKEY("Document No."); IF TempPaymentBuffer.FIND('-') THEN
CLEAR(OldTempPaymentBuffer); TempPaymentBuffer.SETCURRENTKEY("Document No."); TempPaymentBuffer.SETFILTER( "Vendor Ledg. Entry Doc. Type",'<>%1&<>%2&<>%3',TempPaymentBuffer."Vendor Ledg. Entry Doc. Type"::"Credit Memo", TempPaymentBuffer."Vendor Ledg. Entry Doc. Type"::Refund,TempPaymentBuffer."Vendor Ledg. Entry Doc. Type"::Payment); IF TempPaymentBuffer.FIND('-') THEN
Comments
http://en.wikipedia.org/wiki/Get_Smart
http://mibuso.com/blogs/davidmachanick/