Filtering sales price in sales order
julkifli33
Member Posts: 1,100
hi all i want to filter customer sales price in sales order
lets say i set item A, B and C for Customer 001
so when i create sales order for customer 001
the lookup for Item no at detail part only show item A, B,C
how to do that?
thanks
this is my code
but still wrong
lets say i set item A, B and C for Customer 001
so when i create sales order for customer 001
the lookup for Item no at detail part only show item A, B,C
how to do that?
thanks
this is my code
but still wrong
SalesPrice.FILTERGROUP(4); SalesPrice.SETRANGE(SalesPrice."Sales Type",SalesPrice."Sales Type"::Customer); SalesPrice.SETRANGE(SalesPrice."Sales Code",'10000'); SalesPrice.FILTERGROUP(0); IF FORM.RUNMODAL(0,SalesPrice) = ACTION::LookupOK THEN BEGIN //"My Code END;
0
Answers
-
Where you have written this code?
What is your detail part in sales order? is this sales line?julkifli33 wrote:the lookup for Item no at detail part only show item A, B,C
Do you want to lookup only those items in No. field of line table?0 -
page sales order subformvijay_g wrote:Where you have written this code?
i create new field to filter this
or do you think it's better if I filter directly to Sales Line Table , field = No.??0 -
Have you written this code on onlookup trigger of your customized field?
don't disturb the No. field of line.0 -
exactly....vijay_g wrote:Have you written this code on onlookup trigger of your customized field?
don't disturb the No. field of line.
i create new field named Item Number
here is the full code
customer price group TEST, i do it using hardcode firstItem Number - OnLookup(VAR Text : Text[1024];) : Boolean SalesPrice.FILTERGROUP(4); SalesPrice.SETRANGE(SalesPrice."Sales Type",SalesPrice."Sales Type"::"Customer Price Group"); SalesPrice.SETRANGE(SalesPrice."Sales Code",'TEST'); SalesPrice.FILTERGROUP(0); IF FORM.RUNMODAL(0,SalesPrice) = ACTION::LookupOK THEN BEGIN //My code END;
0 -
Do reset to your salesprice first.0
-
hi vijayvijay_g wrote:Do reset to your salesprice first.
it seems like because i forgot to put
if salesprice.find('-') then
now it works
thanks for your help0
Categories
- All Categories
- 75 General
- 75 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 610 NAV Courses, Exams & Certification
- 1.9K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 251 Dynamics CRM
- 103 Dynamics GP
- 6 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 28 Design Patterns (General & Best Practices)
- Architectural Patterns
- 9 Design Patterns
- 4 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1K General Chat
- 1.6K Website
- 77 Testing
- 1.2K Download section
- 23 How Tos section
- 249 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions