locked
Configure VS Lightswitch HTML Client to Phonegap (Adobe Build, Telerik, Apache Cordova) RRS feed

  • Question

  • I have a VS Lightswitch html client SharePoint Online app that is currently hosted on azure. I am looking to configure the app to use cross platform (Phonegap) for either (Adobe PhoneGap Build, Telerik or Apache Cordova). I have searched the web for hours to find documentation to achieve this goal, only thing i found was this blog:

    http://lightswitchhelpwebsite.com/Blog/tabid/61/EntryId/1204/Create-Phone-Gap-Applications-From-LightSwitch-HTML-Client-in-Minutes.aspx

    In that blog it instructs to use NOMAD by Redgate as third party tool to convert the app to phone gap. However, Nomad is currently decommissioned and had advised me to use the following tools (Adobe PhoneGap Build, Telerik or Apache Cordova). Without any documentation or tutorial I have no clue where to start from.

    Any assistance would be greatly appreciated. 

    Thanks for all the help!!

    Sunday, December 7, 2014 5:11 PM

Answers

  • Thanks for the quick reply.

    I would insert this code into the "Index.html."

    Do I need to configure anything in the config.xml file.

    Based on your last statement "I tried to do deeper integration but the LightSwitch run-time is designed to run live not offline." Will there be any enhancement for lightswitch html client in the future to run offline. I find LS HTML valuable source of creating powerful apps, with the advancement offline capability will really be huge support.

    I appreciate your help.

    I have not tried to use Cordova so I do not know if anything needs to be done in the Config.xml

    I do not think they will add offline support in LightSwitch. However you can make a app that uses LightSwitch for the back-end. See:

    Creating a WinJS Application Using LightSwitch OData Back-end


    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book

    http://LightSwitchHelpWebsite.com

    • Marked as answer by Angie Xu Monday, December 15, 2014 5:23 AM
    Sunday, December 7, 2014 8:48 PM

All replies

  • Sorry that there isn't more out there. I have not had a chance to look at the Cordova tools at all and I don't think I will have any time in the next 3 months. However, the LightSwitch integration should come down to the following:

    <!DOCTYPE HTML>
    <html>
    <head>
        <meta charset="utf-8" />
        <meta http-equiv="X-UA-Compatible" content="IE=10" />
        <meta name="HandheldFriendly" content="true" />
        <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no" />
        <meta name="apple-mobile-web-app-capable" content="yes" />
        <title>LightSwitchHelpWebsite</title>
        <script type="text/javascript">
            // Work around viewport sizing issue in IE 10 on Windows Phone 8
            if (navigator.userAgent.match(/IEMobile\/10\.0/)) {
                document.writeln("<style>@-ms-viewport { width: auto!important; }</style>");
            }
        </script>
    </head>
    <body style="margin: 0px; padding:0px; height: 100%; overflow:hidden; ">
    <iframe src="http://blogs.lightswitchhelpwebsite.com/htmlclient/" width="100%" height="100%"></iframe>
    </body>
    </html>

    Basically you have a page that shows the content of your live LightSwitch app in an IFrame.

    I tried to do deeper integration but the LightSwitch run-time is designed to run live not offline.


    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book

    http://LightSwitchHelpWebsite.com

    Sunday, December 7, 2014 5:34 PM
  • Thanks for the quick reply.

    I would insert this code into the "Index.html."

    Do I need to configure anything in the config.xml file.

    Based on your last statement "I tried to do deeper integration but the LightSwitch run-time is designed to run live not offline." Will there be any enhancement for lightswitch html client in the future to run offline. I find LS HTML valuable source of creating powerful apps, with the advancement offline capability will really be huge support.

    I appreciate your help.

    Sunday, December 7, 2014 7:20 PM
  • Thanks for the quick reply.

    I would insert this code into the "Index.html."

    Do I need to configure anything in the config.xml file.

    Based on your last statement "I tried to do deeper integration but the LightSwitch run-time is designed to run live not offline." Will there be any enhancement for lightswitch html client in the future to run offline. I find LS HTML valuable source of creating powerful apps, with the advancement offline capability will really be huge support.

    I appreciate your help.

    I have not tried to use Cordova so I do not know if anything needs to be done in the Config.xml

    I do not think they will add offline support in LightSwitch. However you can make a app that uses LightSwitch for the back-end. See:

    Creating a WinJS Application Using LightSwitch OData Back-end


    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book

    http://LightSwitchHelpWebsite.com

    • Marked as answer by Angie Xu Monday, December 15, 2014 5:23 AM
    Sunday, December 7, 2014 8:48 PM