Make TEXTBOX with Filter

oioi007
Member Posts: 41
Hello!
I want to make TextBox and Command button on a form.
for example Textbox ... PS|JR..AH , so if I push Command button it must select entries with filter values from table. how to code this one?
Thanks
I want to make TextBox and Command button on a form.
for example Textbox ... PS|JR..AH , so if I push Command button it must select entries with filter values from table. how to code this one?
Thanks
0
Comments
-
F7 Is Faster. If you have your heart set on a button you can use sendkeys to progrm F7
how about onValidate of the TEXTBOX
Setrange("The field you want to filter", "Your textbox filter");
you'd have to make a filter clear button then 8-[0 -
im new to NAV, I have some tasks to do..
What you mean in TEXTBOX FILTER?
I just want to make work filters in TEXTBOX, not use F7 and how to make connection with push button and textbox.
Customer.SETRANGE("Salesperson Code"), ?? ;0 -
What I ment by Textbox filter is that you want to use a textbox to hold information. That information is a filter you would like to use.
Do you have access to the OnPush trigger of a command button?0 -
what Savatage mean with "Your textbox filter" is your value in your texbox, quasi your variable (SourceExpr for your Textbox).
Why not should use the user F7. Do you have disabled the filter on permissions :?:
Well, here a solution with filter in a textbox and use this Filter on a Recordvariable.YourTextBoxVariable := 'C|D|B'; YourRecVariable.setfilter(YourFieldToFilter,YourTextBoxVariable); //Now you have filtered the RecordSet in your YourRecVariablecan and you can work with this, for example with a loop
other, if you will use the filter in TextBox in the form u have designd your textbox you can write following behind the Trigger "OnAfterValidate()" in your TextBox
You have entered in your Textbox value like this 'A|B|C'Rec.setfilter(YourFieldToFilter,YourTextBoxVariable); currform.update(false);
RegardsDo you make it right, it works too!0 -
sava, your to fast for me :-DDo you make it right, it works too!0
-
As an example we'll use the customer List Form.
(Might be set as Editable=No - you'll have to change that for this demonstration.
On the form you add global Variable Type Text.
Call it SalesPersonFilter.
On The Form You Will Add a Text Box And Command Button To the Bottom Of The Form (remember Property of these fields Vertglue=Bottom).
The SourceExp of your Textbox will be Your Variable "SalesPersonFilter".
On the Trigger OnPush of the command button you can add
SETRANGE("Salesperson Code",SalesPersonFilter);
Give it a try.
If you put the code onAfterValidate then no button is needed. It just does it once you enter what you want.
Application Designers Guide
http://download.microsoft.com/download/ ... 1w1adg.pdf0 -
garak wrote:sava, your to fast for me :-D0
-
:-D two persons, same idea. so, i go to bed ....
good nightDo you make it right, it works too!0 -
Ok Thanks guys 8)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