Below is my code
@{Html.Telerik().Window()
.Name("SupportDetailCommentPopup")
.Title("Comment")
.Content(@<text>
<form>
<div class="popup-validation-summary" style="display: none;">
<ul class="popup-validation-message-list"></ul>
</div>
<textarea id="SupportDetailCommentText" maxlength="255" style="width: 280px; height:100px" class="t-input ignoreForUnsavedChanges"></textarea>
<ul class="editor-fields">
<li>
@Html.Label("Updated By")
<div id="SupportDetailCommentLastUpdatedByText"></div>
</li>
<li>
@Html.Label("Last Updated Date")
<div id="SupportDetailCommentLastUpdatedDateText"></div>
</li>
</ul>
<input type="button" value="Save" id="FundsAvailableForMonthPopUpSave" onclick="" class="t-button button-spacing" />
<input type="button" value="Cancel" onclick="" class="t-button button-spacing" />
</form>
</text>)
.Modal(true)
.Visible(false)
.Draggable(true)
.ClientEvents(e => e.OnOpen("SupportDetailCommentPopUpOpen"))
.Width(300);
}
e.preventDefault();
PopulateSupportDetailCommentPopUp(e);
$("#SupportDetailCommentPopup").data('tWindow').open();//getting Exception on this line
});
function PopulateSupportDetailCommentPopUp(e)
{
var vm={CommentText:"test",LastUpdated:"SRJ",LastUpdatedDate:"March 21, 2016"};
$("#SupportDetailCommentPopup").data('viewModel', vm);
$('#SupportDetailCommentText').val(vm.CommentText);
$("#SupportDetailCommentLastUpdatedByText").text(vm.LastUpdatedBy);
$("#SupportDetailCommentLastUpdatedDateText").text(vm.LastUpdatedDate);
}