title: Accessing filtersource in MVC Razor syntax
body: <p>How do I implement what's in the <code>change:function(e)</code> in MVC Razor shown below?  I have been pounding my head against this for days and cannot find anything. </p>
  
  <pre><code>$(document).ready(function() {
  var items = [
      {value : '1',
       desc : 'fred'},
      {value : '2',
       desc : 'wilma'},
      {value : '3',
       desc : 'pebbles'},
      {value : '4',
       desc : 'dino'}
  ];
  
  var cb = $('#comboBox').kendoComboBox({
      dataSource : items,
      dataTextField : 'desc',
      dataValueField : 'value',
      filter : 'contains',
      change : function (e) {
          if (this.value() &amp;&amp; this.selectedIndex == -1) {    
              this._filterSource({
                  value: "",
                  field: this.options.dataTextField,
                  operator: "contains"
              });
              this.select(1);
          }
      }
  }).data('kendoComboBox');
  
  $('#showValue').click(function () {
      alert(cb.value());
  });
  
  });
  </code></pre>
  
  <p>working example here --> <a href="http://jsfiddle.net/gVWBf/27/" rel="nofollow">JSFiddle</a></p>
  
  <hr>
  
  <p>Here is what I have so far.  What's inside the <code>if</code> statement doesn't do anything.</p>
  
  <pre><code>function onChange(e) {
      var lT = $("#loadType").data("kendoComboBox").input.val();
      if (lT != "Generic") {
          // Here I need to compare what's entered to what is populated in the comboBox dropdown
          if (this.selectedIndex == -1) {
              this._filterSource({ 
                  value: "",
                  field: this.options.dataTextField,
                  operator: "contains"
              });
              this.select(1);
  
                  //this is for Testing purposes only
                  alert("See Me?");
              }
  
          //this is for Testing purposes only
          alert(lT + " " + this.selectedIndex + " " + this.value());
      }
  };
  </code></pre>
  
  <p>For completeness here is the combobox as well:</p>
  
  <pre><code>&lt;div class="form-group"&gt;
          @Html.LabelFor(model =&gt; model.loadDescrip, new { @class = "control-label col-md-2" })
          &lt;div class="col-md-10"&gt;
              @(Html.Kendo().ComboBox()
                      .Name("loadDescrip")
                      .Filter(FilterType.Contains)
                      .DataTextField("DocCode")
                      .DataValueField("DocCode")
                      .DataSource(source =&gt;
                      {
                          source.Read(read =&gt;
                          {
                              read.Action("GetCascadeDocumentNumbers", "DockDoor")
                                  .Data("filterLoadDescription");
                          })
                        .ServerFiltering(true);
                      })
                      .Enable(false)
                      .AutoBind(false)
                      .CascadeFrom("loadType")
                      .Events(e =&gt;
                          {
                  e.Change("onChange");
                          })
              )
              @Html.ValidationMessageFor(model =&gt; model.loadDescrip)
          &lt;/div&gt;
      &lt;/div&gt;
  </code></pre>