Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Suggested answer

Issue Gift Card

Posted on by 2,597

Hello,

I want to issue gift card on Ax POS but i got this error

Gift-Card-Issue-Error.png

  • Suggested answer
    VinodKumar42 Profile Picture
    VinodKumar42 65 on at
    RE: Issue Gift Card

    Hi Hossam,

    I don't know why no one mentioned about AX Gift card policy sets here, it's the place where you define the numbering for the gift cards.You must be missing that.

    You need to navigate to Retail>Setup>Gift Cards> Policy Sets. and see if policy is defined there. Basically you can set the numbers here in the Number from and Number to fields and then define the other properties like, minimum reload amount and max balance amount.

    Once done with above you should be able to create gift cards from your POS machine using RTS.  

    I hope this will fix the issue. Good luck.

    Regards,

    Vinod Kumar

  • Hossam Fathy Profile Picture
    Hossam Fathy 2,597 on at
    RE: Issue Gift Card

    Hi Shaimaa,

    I am really so happy by your quick reply Thank you.

    This is the link to the new case.

    community.dynamics.com/.../upload-gift-card

  • RE: Issue Gift Card

    Hi Hossam ,

    Please raise a new question or i would prefer support request so we can help you on that.

  • Hossam Fathy Profile Picture
    Hossam Fathy 2,597 on at
    RE: Issue Gift Card

    Hi Shaimaa,

    Thx for your support.

    So it is Hardcoded , Surprise.

    Ok now i have one more question.

    my customer will start use the system for the 1st time and they already sold gift cards, how i can upload sold cards into Ax.

    Thank you.

  • Suggested answer
    RE: Issue Gift Card

    Hi Hossam, 

    this is mandatory setup you can do the range as you want  and be sure that the card id is equal "GIFTCARD" as it's hardcoded .

    You can find this validation at calss RetailTransactionServiceTransactions\validateCardNumberMatchesSetup


    while select cardNumberFrom,cardNumberTo from retailTenderTypeCardNumbers
    where retailTenderTypeCardNumbers.cardTypeId == 'GIFTCARD'
    {
    lengthToCompare = max(strLen(retailTenderTypeCardNumbers.cardNumberFrom), strLen(retailTenderTypeCardNumbers.cardNumberTo));
    cardSubString = subStr(_cardNumber, 0, lengthToCompare);

    if (strCmp(retailTenderTypeCardNumbers.cardNumberFrom, cardSubString) <= 0
    && strCmp(retailTenderTypeCardNumbers.cardNumberTo, cardSubString) >= 0)
    {
    isCardNumberMatchsSetup = true;
    }
    }

  • Hossam Fathy Profile Picture
    Hossam Fathy 2,597 on at
    RE: Issue Gift Card

    Hi Shaimaa,

    Hossam not Hassan .

    Is There any place where I can check the card number setup in Ax.

    The 9 u asked me to put just to restrict using cards starting by 9, but if I want to use any numbers so I can keep this setup blank.

  • RE: Issue Gift Card

    Hi Hossam,

    Then please open support ticket with MS support so we can investigate further .

  • Hossam Fathy Profile Picture
    Hossam Fathy 2,597 on at
    RE: Issue Gift Card

    Hi Shaimaa,

    Thx for reply.

    I already did this.

    Now my card should start by number 9 and i can use any number of digits, right? i tested again and same error above.

    This is the error from the event viewer

    Microsoft.Dynamics.Retail.Pos.GiftCard.GiftCardForm, Text: Issue gift card: Microsoft.Dynamics.Retail.Pos.GiftCard.GiftCardException: The gift card number not matching the set up.

      at Microsoft.Dynamics.Retail.Pos.GiftCard.GiftCardController.IssueGiftCard()

      at Microsoft.Dynamics.Retail.Pos.GiftCard.GiftCardForm.Execute().

  • Suggested answer
    RE: Issue Gift Card

    Hi Hossam,

    you can perform card number setup as below : 

    1. On AX side, Retail > Setup > payment methods -> Select Card Numbers.
    2. Click on "New".
    3. Select "Gift Card" from drop down.
    4. Enter start from and to and digits to identify.
    5. Send data to channel db
    6. Now, Issue gift card from POS. 

    pastedimage1594202026561v2.png

    Card number validation is required for payment processing when a customer presents a card. You set up the length and range of card numbers that are acceptable for each card type.

    For example, some credit cards are identified by a unique starting number, such as the number 4. To identify and validate this card type in the system, you enter 4 in the Card number from and Card number to fields, and enter 1 in the Digits to identify field. Any time a card is used that begins with the number 4, the system identifies the card as this specific card type.

    You can also enter a range of values to identify a specific card type. For example, if you want to identify a specific card that always starts with a value of 4200 to 4300, you enter 4200 in the Card number from field and 4300 in the Card number to field, and enter 4 in the Digits to identify field.

    For more info ,please check this article https://docs.microsoft.com/en-us/dynamicsax-2012/appuser-itpro/set-up-card-types-and-card-numbers

  • Hossam Fathy Profile Picture
    Hossam Fathy 2,597 on at
    RE: Issue Gift Card

    Hi Ramune,

    is this required support case,

    you cant support me in this community.

    Where is the place in Ax to define the Gift Card Numbers?

    Can i add the gift card number to Ax without amount then sell them on the POS.

    Also if i have Gift Cards with Different Values how to add them on Ax.

    Thank you.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Complete!

🔔 Be sure to subscribe to the new forums you are interested in to stay up to date! 🔔

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,101 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 229,896 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans