1. #1
    Ext User
    Join Date
    Aug 2007
    Posts
    99
    Vote Rating
    0
    bcamp1973 is on a distinguished road

      0  

    Default simple TriggerField() example?

    simple TriggerField() example?


    can someone point me in the direction of a simple TriggerField() example. i'd like to have a search field with the little magnifying glass button as in this example...

    http://extjs.com/deploy/dev/examples/form/custom.html

    but the included SearchField.js is far more than i need...and the code is a bit over my head

  2. #2
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,117
    Vote Rating
    507
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      0  

    Default


    It's only a few lines, which bits don't you understand?

  3. #3
    Ext User
    Join Date
    Aug 2007
    Posts
    99
    Vote Rating
    0
    bcamp1973 is on a distinguished road

      0  

    Default


    well, it looks like it's trying to extend another class? isn't there a simple way to do an inline TriggerField()? Same as you would for a comboBox() or TextField()?

  4. #4
    Ext User
    Join Date
    Jan 2008
    Posts
    85
    Vote Rating
    0
    jonn is on a distinguished road

      0  

    Default


    If you mean you just want the magnifying glass then just change the triggerClass to x-form-search-trigger.

  5. #5
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,251
    Vote Rating
    73
    Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold

      1  

    Default


    Example:

    Code:
    var triggerField = new Ext.form.TriggerField({
    	'fieldLabel': 'Search',
    	'triggerClass': 'x-form-search-trigger',
    	'onTriggerClick': function() {
    		// perform search
    	}
    });

  6. #6
    Ext User
    Join Date
    Aug 2007
    Posts
    99
    Vote Rating
    0
    bcamp1973 is on a distinguished road

      0  

    Default


    That's exactly what i was looking for, thanks again Condor!

  7. #7
    Ext Premium Member
    Join Date
    Mar 2010
    Posts
    42
    Vote Rating
    0
    jasmina is on a distinguished road

      0  

    Default


    How can i get the value entered in the text field?

  8. #8
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,251
    Vote Rating
    73
    Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold

      0  

    Default


    Code:
    onTriggerClick: function() {
      var value = this.getValue();
      ...
    }

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar