No ratings

Known Issue: Scrolling on a SharePoint Page Viewer Web Part using a Mobile Device does not Work


Known Issue: Scrolling on a SharePoint Page Viewer Web Part using a Mobile Device does not Work

This article has been archived, and/or refers to legacy products, components or features. The content in this article is offered "as is" and will no longer be updated. Archived content is provided for reference purposes only. This content does not infer that the product, component or feature is supported, or that the product, component or feature will continue to function as described herein.



SmartForms can be inserted in SharePoint pages using K2 Form Viewer or K2 SmartForms Viewer, which inherits from the SharePoint Page Viewer web part.  When the form is viewed on a mobile device, such as an iPad, the scroll bar is not available which makes the form unusable. To resolve this issue, you must enable page scrolling by adding a script to the SharePoint page hosting the K2 Form Viewer. Follow the steps detailed in the workaround below:



  1. As a SharePoint administrator edit the SharePoint page that contains the K2 Forms Viewer web part.
  2. In the ribbon choose Insert -> Embed Code.
  3. Paste the following code:
    1. The sample script below shows the configuration for an iPad. Customize the script if you are using a different mobile device.
    2. The widths and heights in the script can be adjusted to ensure the form displays correctly on the targeted devices.

    <script type="text/javascript">
    var is_iPad = navigator.userAgent.match(/iPad/i) != null;
    function _fixIframeScrolling()
        var iframe = document.getElementsByTagName("iframe")[0];
        iframe.setAttribute("scrolling", "yes");
        iframe.height = "100%";
        iframe.width = "100%"; = "display:block;"; = "height: 450px; width: 750px; max-width: 750px; max-height: 450px; overflow: auto; -webkit-overflow-scrolling: touch;"; = "height: 460px; width: 760px;";
  4. Click Insert.
  5. Save the page.


Labels: (1)
Version history
Last update:
‎05-20-2021 05:53 AM
Updated by: