On lookup trigger (form)

apickard
Member Posts: 42
Hi guys,
I am wasting a lot of time on something which I believe is trivial to solve. Can anyone help me?
I've got a field (of type Code) which has it's On lookup trigger working perfectly - (if no code is inseted on the On lookup trigger). However I need to insert some code on the On lookup trigger so that lookup form displays only a set of filtered records.
This filtering is working fine, however the lookup form does not display the Ok and Cancel Button, and user cannot select any record from this lookup list.
Any help please?
I am wasting a lot of time on something which I believe is trivial to solve. Can anyone help me?
I've got a field (of type Code) which has it's On lookup trigger working perfectly - (if no code is inseted on the On lookup trigger). However I need to insert some code on the On lookup trigger so that lookup form displays only a set of filtered records.
This filtering is working fine, however the lookup form does not display the Ok and Cancel Button, and user cannot select any record from this lookup list.
Any help please?
0
Comments
-
You need to seed LookupMode(TRUE) on the form that you use for lookup.0
-
Shedman,
thanks a lot, it works - buttons are showing.0 -
However when selecting a value/record from the filtered list it does not pick/return the value selected to the originating form. Any ideas?0
-
Please post your code.
What you need to do after the selection is copy the value from the record that was used in the lookup to your current record.IF LookupForm.RUNMODAL = ACTION::LookupOK THEN Rec.Field := LookupRec.FIELD;
0 -
Do you make it right, it works too!0
-
Hi Shedman,
thanks a lot - issue solved, however had to add also the following line
Form.Getrecord
before the assignment statement.
Garak,
apologies for that however I noticed my mistake and added a comment stating that I've copied my original post to the correct forum. Unfortunately once posted I did not have the facility to delete my original post. Thanks anyway0
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