web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics NAV (Archived)

The filter "@<Buy from Vendor No.>" on the Buy-from Vendor No. field in Purchase Header table has no lower bound

(0) ShareShare
ReportReport
Posted on by 60

Hi,

I am getting above error while trying to change the 'Buy from Vendor No.' in purchase order.

Steps to recreate the error:

1. Open the purchase order list.

2. Then add a filter of a "Buy-from Vendor No.".

3. I chose one of the purchase order from the filtered list.

4.In the card I when I tried to change the 'Buy from Vendor No.', its giving following error.

When I debugged, its showing error in IF GETRANGEMIN("Buy-from Vendor No.") = GETRANGEMAX("Buy-from Vendor No.") THEN of Skipinitialization() function.

Can you please help?

*This post is locked for comments

I have the same question (0)
  • sha212 Profile Picture
    60 on at
    RE: The filter "@<Buy from Vendor No.>" on the Buy-from Vendor No. field in Purchase Header table has no lower bound

    Hello José ,

    It worked. Thank you.

    Another way is to filter using 'Pay to Vendor No.' and then change in the card. I am not sure why Buy from Vendor No. is not working.

  • sha212 Profile Picture
    60 on at
    RE: The filter "@<Buy from Vendor No.>" on the Buy-from Vendor No. field in Purchase Header table has no lower bound

    Currently OnInsert tigger following code is there.

    IF NOT SkipInitialization THEN

     InitInsert;

    IF GETFILTER("Buy-from Vendor No.") <> '' THEN

     IF GETRANGEMIN("Buy-from Vendor No.") = GETRANGEMAX("Buy-from Vendor No.") THEN

       VALIDATE("Buy-from Vendor No.",GETRANGEMIN("Buy-from Vendor No."));

    I commented the first line still getting error.

  • Suggested answer
    jcastro Profile Picture
    2,245 on at
    RE: The filter "@<Buy from Vendor No.>" on the Buy-from Vendor No. field in Purchase Header table has no lower bound

    Hello sha212,

    Instead of filtering the P.O., you can try sort by the buy-from vendor No. and use the search feature to find your purchase order. After that enter the card and make your change (not having filtered the list previously).

    Best regards,

  • Suggested answer
    Suresh Kulla Profile Picture
    49,097 Super User 2025 Season 2 on at
    RE: The filter "@<Buy from Vendor No.>" on the Buy-from Vendor No. field in Purchase Header table has no lower bound

    I don't see that call in the newest version. I believe you can comment that. This is how the code in the newest version, in the OnInsert trigger

                  InitInsert;

                  IF GETFILTER("Buy-from Vendor No.") <> '' THEN

                    IF GETRANGEMIN("Buy-from Vendor No.") = GETRANGEMAX("Buy-from Vendor No.") THEN

                      VALIDATE("Buy-from Vendor No.",GETRANGEMIN("Buy-from Vendor No."));

                  IF "Purchaser Code" = '' THEN

                    SetDefaultPurchaser;

  • sha212 Profile Picture
    60 on at
    RE: The filter "@<Buy from Vendor No.>" on the Buy-from Vendor No. field in Purchase Header table has no lower bound

    The condition   IF GETFILTER("Buy-From Vendor No.") <> '' THEN     is there already. I have not made any changes to skipintialization() function.  

  • Suggested answer
    Suresh Kulla Profile Picture
    49,097 Super User 2025 Season 2 on at
    RE: The filter "@<Buy from Vendor No.>" on the Buy-from Vendor No. field in Purchase Header table has no lower bound

    Add the IF before IF GETRANGEMIN.... condition like

    IF GETFILTER("Buy-From Vendor No.") <> '' THEN

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Mansi Soni – Community Spotlight

We are honored to recognize Mansi Soni as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics NAV (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans