ActivityIndicator doesn't work

6 posts, 0 answers
  1. TJ
    TJ avatar
    58 posts
    Member since:
    Aug 2013

    Posted 05 Jan 2015 Link to this post

    I was attempting to use an ActivityIndicator (https://github.com/NativeScript/docs/blob/master/ApiReference/ui/activity-indicator/HOW-TO.md), but when I instantiate a ActivityIndicator() object my app crashes on iOS and Android.

    Thanks,
    TJ
  2. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 06 Jan 2015 Link to this post

    Hi TJ,

    Can you post more info about the error? You can use the tip provided in this post to get more info about the error.

    Regards,
    Vlad
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. TJ
    TJ avatar
    58 posts
    Member since:
    Aug 2013

    Posted 06 Jan 2015 in reply to Vlad Link to this post

    Hi Vlad,

    The ActivityIndicator is no longer crashing for me (not sure why), but it doesn't appear to do anything. I've tried putting these three lines of JS in my page's load method:

    var activityIndicatorModule = require( "ui/activity-indicator" );
    var indicator = new activityIndicatorModule.ActivityIndicator();
    indicator.set( "busy", true );

    ...but nothing happens. I also tried adding an <ActivityIndicator busy="true" /> to my page, but that doesn't display anything either. Any idea what I need to do to get this to work? I don't see anything else in the docs.

    Thanks,
    TJ
  4. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 07 Jan 2015 Link to this post

    Hello TJ,

    We have ActivityIndicator in our cuteness.io app details page. Can you try it? 

    Regards,
    Vlad
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  5. TJ
    TJ avatar
    58 posts
    Member since:
    Aug 2013

    Posted 07 Jan 2015 Link to this post

    Hey Vlad,

    After looking at Cuteness I was able to get this working and the problem was on my end. I'll make one feature suggestion though: if we could add the ability to show a message with the spinner (like this Cordova plugin does http://plugins.telerik.com/plugin/spinner) that would be awesome.

    Anyways, thanks for your help.
    TJ
  6. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 08 Jan 2015 Link to this post

    Hi TJ,

    Since such kind of dialog is not native for native mobile platforms the closest option we can offer for now is custom dialog from our dialogs module with some text. Here is an example:

    ...
    var dialogs = require("ui/dialogs");
    var dialog = new dialogs.Dialog("Loading...");
    dialog.show();
    ...


    Regards,
    Vlad
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top