Hello,
I've copied and pasted the Demo for DocumentEditor but when I press the comment button, the comment window pops up greyed out and I cannot write or click anything.
It looks like @section Scripts isn't rendering. I've followed the instruction and added all the necessary code. What could be the issue here?
Hi William,
Can you please share us your document editor version details.
Regards,
Ajithamarlin E
Hi Ajithamarlin,
The code below is taken from the sample project source file so I did not make any changes from what is shown in the demo.
literally every other components work except the comments.
@{
ViewBag.Title = "DocumentEditor";
Layout = "~/Views/Shared/_Layout.cshtml";
}
@using Syncfusion.EJ2
<script src="~/scripts/documenteditor/import-helper.js"></script>
<div id = "ControlRegion">
<div class="control-section">
<div class="control-section">
<div id='documenteditor_titlebar' class="e-de-ctn-title"></div>
<ejs-documenteditorcontainer id="container" enableToolbar=true height="590px"></ejs-documenteditorcontainer>
</div>
</div>
</div>
<script>
var documenteditor;
document.addEventListener('DOMContentLoaded', function () {
var documenteditorElement = document.getElementById("container");
documenteditorElement.style.height = "590px";
documenteditorElement.style.width = "100%";
var container = documenteditorElement.ej2_instances[0];
container.showPropertiesPane = false;
documenteditor = container.documentEditor;
documenteditor.currentUser = "user";
documenteditor = documenteditorElement.ej2_instances[0].documentEditor;
documenteditorElement.ej2_instances[0].serviceUrl = '/api/documenteditor/';
var ajax = new ej.base.Ajax("@Url.Content("~/scripts/documenteditor/data-default.json")", 'GET', true);
ajax.send().then();
ajax.onSuccess = function (data) {
documenteditor.open(data);
documenteditor.documentName = 'Getting Started';
documenteditor.showComments = true;
updateDocumentTitle();
};
documenteditor.documentChange = function (args) {
updateDocumentTitle();
};
titleBarDiv = document.getElementById('documenteditor_titlebar');
initComponentAndWireEvent();
});
</script>
<style>
... //did not paste since its too long.
</style>
Hi William,
We have tried in below sample and couldn't reproduce the reported issue. Can you please check it?
If you still facing the issue, Please share the document editor version details with how you have referred syncfusion scripts and then if possible, please share the video illustration. We suspect that any css overriden in your application.
Regards,
Suriya M.