Syncfusion.EJ2.DropDowns.DropDownListBuilder

.CSHTML
    <div class="frame">
        <div class="row">
            <div class="col-xs-8 col-sm-4">
                <span class="txt">Select Group</span>
                @Html.EJS().DropDownList("jobList").DataSource(dataManger => { dataManger.Url("/Api/JobNumber").Adaptor("UrlAdaptor"); })
            </div>
        </div>
    </div>


Result

Select Job
Syncfusion.EJ2.DropDowns.DropDownListBuilder

It doesn't seem to call API



1 Reply

KR Keerthana Rajendran Syncfusion Team April 11, 2018 10:43 AM UTC

Hi Dave,   
   
Thank you for contacting Syncfusion Support.   
   
This issue occurs, because you have not used .Render() in your razor code. Also, map the field from DropDownList and mention proper adaptor type as shown below.   
   
@Html.EJS().DropDownList("customers").DataSource(dataManger =>{dataManger.Url("/api/Values").Adaptor("WebApiAdaptor").CrossDomain(true);}).Fields(newSyncfusion.EJ2.DropDowns.DropDownListFieldSettings { Value = "OrderID", Text = "CustomerID" }).Width("300").Render()   
   
We have attached a sample for reference which can be downloaded from the below link.   
   
   
Please refer to the below UG link.   
   
   
Regards,                                                                        
Keerthana.   
 


Loader.
Up arrow icon