Changing "Description" Entry

Savatage
Member Posts: 7,142
There are codes in Navision where you can type in the Description and the proper code appears.
For example in Payment journal if I don't know the g/l for Inventory I can type in "INVE" and 15000 - Inventory would appear.
Same goes true for order entry if i start to enter an item description into the item number it will pop up the first hit.
My question is can this be changed to recognize another field other than the description field? Each item we have has two numbers - i would like to enter either number into the No. field and the proper item will appear.
we use the No. & No 2. fields - if No 2 could replace how the description works it would make my day, but not system wide just where we need it (order entry) (item Journals)!
For example in Payment journal if I don't know the g/l for Inventory I can type in "INVE" and 15000 - Inventory would appear.
Same goes true for order entry if i start to enter an item description into the item number it will pop up the first hit.
My question is can this be changed to recognize another field other than the description field? Each item we have has two numbers - i would like to enter either number into the No. field and the proper item will appear.
we use the No. & No 2. fields - if No 2 could replace how the description works it would make my day, but not system wide just where we need it (order entry) (item Journals)!
0
Comments
-
It is actully not the description field, but the "Search Name" field. It is defined by setting the property AltSearchField on the No. field in the Item and G/L Account (and so on) tables. So you can change this property, but then you will change it for the table system wide. Or you could move the Description.OnValidate code to the "No. 2".OnValidate (well, should be slightly adjusted :-))
I don't think you can code it on a few forms, because the the table relation is checked before the form's OnValidate is executed. Then you have to change the ValidateTableRelation as well, and that has a lot of negative sideeffects.
I will recommend changing the code that fills the "Search Name/Description" - that will make it clear and constant for the users.Regards
Peter0 -
AltSearchField - never noticed it
i'll give a shot - thanks0 -
I finally had a chance to try this.
I changed the Alt Search Field on the Item Table to No.2
-It did allow me to enter No .2 into the Item# of the sales order & got the proper result
-The Item Journal it doesn't work - I think I need to change
Codeunit 240 ItemJnlManagement - ItemJnlMgt.OnAfterInputItemNo(Text);
to have the same behavior occur.Code OnAfterInputItemNo(Text) IF Text = '' THEN EXIT; IF EVALUATE(Number,Text) THEN EXIT; Item."No." := Text; IF Item.FIND('=>') THEN IF COPYSTR(Item."No.",1,STRLEN(Text)) = UPPERCASE(Text) THEN BEGIN Text := Item."No."; EXIT; END; Item.SETCURRENTKEY("Search Description"); Item."Search Description" := Text; Item."No." := ''; IF Item.FIND('=>') THEN IF COPYSTR(Item."Search Description",1,STRLEN(Text)) = UPPERCASE(Text) THEN Text := Item."No."; GetItem(ItemNo,ItemDescription) IF ItemNo <> OldItemNo THEN BEGIN ItemDescription := ''; IF ItemNo <> '' THEN IF Item.GET(ItemNo) THEN ItemDescription := Item.Description; OldItemNo := ItemNo; END;
I changed "Search Description" to "No. 2" & it works great - It's been hailed already as the greatest change ever in our company - ha ha \:D/0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K 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
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions