RE: To find the position of the last 3 letters of Customer No.
Thanks for the suggestion.I will check and let u know people.
But one more issue i got where i have to first find the doc no from sales line then i have to assign it to the temp table and from temp table i have to check that sales order no is there in Sales header table and if there then i have to display the records, following is my code but the cursor is not going to the line shipped oty condition: please suggest how to solve this as not getting the value in temp table field:
IF recCustomer.GET(pCustomerNo) THEN
BEGIN
lrecSalesLine.RESET;
lrecSalesLine.SETRANGE("Document Type",lrecSalesLine."Document Type"::Order);
lrecSalesLine.SETRANGE("Sell-to Customer No.",pCustomerNo);
lrecSalesLine.SETRANGE("Part/Unit",pItemTypeFilter);
IF lrecSalesLine.FINDSET THEN
BEGIN
//REPEAT
IF (lrecSalesLine."Quantity Shipped" < lrecSalesLine.Quantity) THEN ///Cursor is not coming here
BEGIN
recSalesTemp."No.":=lrecSalesLine."Document No.";
recSalesTemp.INSERT;
END;
// UNTIL lrecSalesLine.NEXT=0;
END;
END;
lrecSalesHeader.RESET;
//lrecSalesHeader.COPYFILTERS(lrecSalesLine);
lrecSalesHeader.VALIDATE("No.",recSalesTemp."No."); //directly cursor comes here after sales line filteration
IF lrecSalesHeader.FINDSET THEN
ExpCallOffExistingOrder.SETTABLEVIEW(lrecSalesHeader);
//MESSAGE('%1',recSalesTemp."No.");