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 : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

RTE not loading

Thread ID:

Created:

Updated:

Platform:

Replies:

118431 Mar 8,2015 05:27 PM UTC Mar 16,2015 07:41 AM UTC ASP.NET MVC 7
loading
Tags: RichTextEditor
lc
Asked On March 8, 2015 05:27 PM UTC

HI,

i started a new MVC 5 Project in VB.NET and only selected the RTE Element for that project. Libraries are loaded in _Layout.vbhtml

@Styles.Render("~/Content/css")
    @Scripts.Render("~/bundles/jquery")
    @Scripts.Render("~/bundles/modernizr")
     <link rel='nofollow' href="@Url.Content("~/Content/ej/web/Default-theme/ej.widgets.all.min.css")" rel="stylesheet"/>
     <script src="@Url.Content("~/Scripts/jquery-1.10.2.min.js")"></script>
    <script src="@Url.Content("~/Scripts/jsrender.min.js")"></script>
    <script src="@Url.Content("~/Scripts/jquery.easing-1.3.min.js")"></script>   
    <script src="@Url.Content("~/Scripts/jquery.globalize.min.js")"></script>
    <script src="@Url.Content("~/Scripts/ej/ej.web.all.min.js")"></script>
    <script src="@Url.Content("~/Scripts/ej/ej.unobtrusive.min.js")"></script>
...
    @code
        Html.EJ().ScriptManager()
    End Code

in my web.config the following assebmlies are loaded:
<compilation debug="true" targetFramework="4.5">
      <assemblies>
        <add assembly="Syncfusion.Core, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=632609B4D040F6B4" />
        <add assembly="Syncfusion.Compression.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.EJ, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.EJ.Mvc,Version=12.4500.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.Linq.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.XlsIO.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.EJ.Olap,Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.Olap.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
      </assemblies>
    </compilation>
...
<compilation debug="true" targetFramework="4.5">
      <assemblies>
        <add assembly="Syncfusion.Core, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=632609B4D040F6B4" />
        <add assembly="Syncfusion.Compression.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.EJ, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.EJ.Mvc,Version=12.4500.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.Linq.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.XlsIO.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.EJ.Olap,Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
        <add assembly="Syncfusion.Olap.Base, Version=12.4450.0.24, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
      </assemblies>
    </compilation>

But when i try to instantiate a rte in my view with:

@Html.EJ.RTE("Test")

or 
@Html.EJ.RTEFor(Function(model) model.Content)

i am just seeing a textarea with content: <div></div>

it seems to me that the Client Part of the Editor is not loaded, but i have no idea why.

thanks for your help.

kind regards
lc

Attachment: syncfusion_error_image_c4181ae0.rar

Kasithangam C [Syncfusion]
Replied On March 9, 2015 07:39 AM UTC

Hi Ic,

 

We have analyzed your query and we suspect that the problem here is, not proper configuration in the following cases.

 

1. Ensure the following basic syncfusion DLL’s are referred in your application or not.

       Syncfusion.EJ.dll

       Syncfusion.Ej.mvc.dll

 

2. In our application we have web.config file present in the Application -> Views Folder -> web.config file. In that, we need to include the following namespace.

 

Please add the following code snippet to Views web.config file.

 

<code>

[web.config]

<system.web.webPages.razor>

    <host factoryType="System.Web.Mvc.MvcWebRazorHostFactory, System.Web.Mvc, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />

    <pages pageBaseType="System.Web.Mvc.WebViewPage">

      <namespaces>

        <add namespace="Syncfusion.JavaScript" />

        <add namespace="Syncfusion.MVC.EJ" />

      </namespaces>

    </pages>

  </system.web.webPages.razor>

</code>

 

We have a documentation to create our component in ASP.NET MVC which explains full details about how to use our controls and what are the references, script files are and CSS files are needed to add for an application in MVC and please find the below documentation link to create the MVC project manually with our components.

 

http://help.syncfusion.com/ug/js/default.htm#!Documents/createmanually.htm

 

 

For your convenience, we have prepared the simple sample to create the RTE component and please find the sample under the following link.

 

Sample Link: Sample

 

Could you please check with the above sample? If still you face any problem, please get back to us we will be happy to serve you.

 

Kindly let us know if you have further queries,

Regards,

Kasithangam


lc
Replied On March 10, 2015 10:05 AM UTC

the sample worked fine for me. after many tries getting this to work following line helped
<add key="UnobtrusiveJavaScriptEnabled" value="true" />

Kasithangam C [Syncfusion]
Replied On March 11, 2015 06:38 AM UTC

Hi Ic,

We would like to suggest that, when we set the value of “UnobstrusiveJavascriptEnabled” as false in the web.config file, RTE control doesn’t render properly. To resolve this issue, we need to refer our EJ ScriptManager under the @RenderBody() in _Layout.vbhtml page. Please find the below code for the same,

<code>

[_Layout.vbhtml]

<div class="container body-content">

        @RenderBody()

        @Html.EJ().ScriptManager()

    </div>

    @RenderSection("scripts", required:=False)

</code>

If still you face any problem please get back to us. We will be happy to help you out.

Regards,

Kasithangam



lc
Replied On March 12, 2015 02:27 PM UTC

Hi Kasithangam,
the default Syncfusion MVC _Layout.vbhtml has the following part of code:

<div class="container body-content">
        @RenderBody()
        <hr />
        <footer>
            <p>&copy; @DateTime.Now.Year - My ASP.NET Application</p>
        </footer>
</div>
     @code
        Html.EJ().ScriptManager()
    End Code

Unfortunately the View is only showing a Textarea and not the RTE with “UnobstrusiveJavascriptEnabled” as false.  

Due to legal reasons i cannot post my current project, but fortunately a new set up project (using Syncfusion Wizard) is dealing with the same problem. I have edited Home/Index to display the error. See attachment: Due to upload errors the file can be found here: SyncfusionRTETestApplication.rar

Kind regards,

lc


Kasithangam C [Syncfusion]
Replied On March 13, 2015 06:30 AM UTC

Hi Ic,

We have checked with your provided code. We found that, the EJ ScriptManager render code is used in the _Layout.vbhtml page which causes the specified RTE control doesn’t rendering. To resolve this issue, we need to specify @ symbol before EJ ScriptManager, this is the format we need to specify script manager and our controls rendering in MVC.Please find the below code for same,

<code>

    <div class="container body-content">

        @RenderBody()

        <hr />

        <footer>

            <p>&copy; @DateTime.Now.Year - My ASP.NET Application</p>

        </footer>

    </div>

     

     @Html.EJ().ScriptManager()

</code>

And also, we have modified your sample that you have attached. Please find the below modified sample link,

        Sample: RTE Sample

        Please let us know if you have further queries.

        Regards,

        Kasithangam



lc
Replied On March 14, 2015 07:54 AM UTC

Thank you for your detailed help!

Changing this part to @Html.EJ().ScriptManager() worked for the project.

Maybe this is an issue for the wizard?

Kasithangam C [Syncfusion]
Replied On March 16, 2015 07:41 AM UTC

Hi Ic,

Thanks for your update,

Query: Changing this part to@Html.EJ().ScriptManager()worked for the project.Maybe this is an issue for the wizard?

We would like to inform you that, this is not an issue in our side. This is the proper format we are maintaining the script manager and thanks for sharing your information.

Please let us know if you have further queries.

Regards,

Kasithangam


CONFIRMATION

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.

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

;