We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Method to select row by task id.

Thread ID:





124169 May 23,2016 08:22 AM UTC May 24,2016 12:46 PM UTC JavaScript 1
Tags: ejGantt
Anton Goldovsky
Asked On May 23, 2016 08:22 AM UTC

Could you add "selectRowByTaskId" method to Gantt component. It would be useful for me.

Mahalakshmi Karthikeyan [Syncfusion]
Replied On May 24, 2016 12:46 PM UTC

Hi Anatoliy, 
Thanks for contacting Syncfusion support. 
At present there is no built in support to select a row by its taskId. So we have logged feature report regarding this. A support incident has been created under your account to track the status of this requirement. Please log on to our support website to check for further updates. 
But we can provide work around solution for this now by getting index of the row with its taskId then selecting the row using setModel. Please refer the below code example for details. 
   Enter TaskId to select:  <input type="text" id="taskid" /> 
   input type="button" id="selectrow" value="Select Row" onclick="funcSelectRow();" /> 
   <div id="gantt" style="height:350px;width:100%;"></div> 
   <script type="text/javascript"> 
        $(function () { 
        function funcSelectRow(args) { 
            var obj = $("#gantt").data("ejGantt"), 
                model = obj.model, 
                searchItem = document.getElementById('taskid').value, 
                results = model.updatedRecords, 
                index = -1; 
            filterindex = results.some(function (record) { 
                if (record.item.taskID == searchItem) { 
                    index = record.index; 
                    return true; 
            obj.option("selectedRowIndex", index); 
We have also prepared a sample based on this and you can find the sample under the following location 
Mahalakshmi K. 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon