Ticket T312758
Visible to All Users

How to create an ASP.NET MVC application with the HTML 5 Document Viewer control

created 9 years ago

[DevExpress Support Team: CLONED FROM T264015: Web Report Designer - "To be able to run the Report Designer, the client web browser must support HTML5." error is displayed]
WOuld you be able to create single asp mvc project that displays only one page with html 5 document viewer ?

Show previous comments (2)

    Not sure how to resolve it tho…

    Yaroslav (DevExpress Support) 9 years ago

      Hi   Sebastian,
      It seems there is an issue with Knockout bindings, but it's hard to say for sure what causes it. Can you confirm that you included all the required client libraries as described in the Why doesn't the ASPxReportDesigner control/MVC ReportDesigner extension work and client-side errors are thrown KB article? If would also be great if you can share your project with us so we take a closer look at it and see if there are any leads.
      I hope to hear from you soon.

        Looks like its because I am using conflicking jquery 2.2… But some parts of my app may need it.
        Another problem is that even if I remove jquery 2.2 Ive got a report and control showing but I cannot interact with it.

        Answers approved by DevExpress Support

        created 9 years ago

        Hi,

        I have reviewed your project and found that the embedRequiredClientLibraries option is enabled in the web.config file. Note that when this option is enabled, all the script libraries that are required for our scripts are registered automatically. So, the following script libraries are registered along with the WebDocumentViewer scripts:
        -jQuery 1.10
        -jQuery UI 1.10 (both JavaScript and CSS files)
        -globalize
        -knockout 3.3.0

        As the jQuery script was already registered on your webpage, the version conflict occurs and breaks the page. To solve this issue, I suggest you disable the embedRequiredClientLibraries option and register the required script libraries on your webpage manually. In this case, register all the libraries listed above except for jQuery to avoid version conflicts. After that, please check your browser's console to make sure that client-side exceptions are not thrown when your page is previewed in the browser.

          Show previous comments (4)
          DevExpress Support Team 9 years ago

            Hi,

            Thank you for providing me with the screenshot. This problem may be related to the style sheets applied in your application, but I cannot say this for sure without being able to examine your current implementation approach. Would you please modify your previous sample project to demonstrate the issue? I will examine it and do my best to find an appropriate solution.

            I am looking forward to hearing from you.

              I am not convinced that this will be the css issue. As soon as i remove reference to jqery 2… all works as expected.

              Vasily (DevExpress Support) 9 years ago

                Hi,

                I was able to reproduce the issue you are talking about by using the sample project you sent earlier. This issue is caused by the fact that the Angular JS and DevExtreme Web App JS scripts are registered on your web page. These libraries conflict with the Knockout JS and WebDocumentViewer scripts. That's because both Angular JS and  Knockout JS are javascript MVVM frameworks and it is not possible to use both these frameworks on one page.
                To resolve this issue, you can remove the Angular JS framework from your web page and register the Knockout JS  framework instead. In this case, both the DevExtreme Web App JS and WebDocumentViewer  will use this framework and there will be no conflict.
                In any case, the best solution will be to use different Layout views for the views that use DevExtreme widgets and DevExpress MVC extensions. In this case, each layout page will contain only required libraries and there won't be any conflicts.
                Let us know if you need any additional assistance with this.

                Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

                Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.