- Home
- Forum
- Xamarin.Forms
- Busy indicator on start
Busy indicator on start
Hello,
Is it possible to use Busy Indicator in a splash screen during app start on Android and Ios?
Best regards
SIGN IN To post a reply.
5 Replies
1 reply marked as answer
RB
Rabhia Beham Kathar Mideenar
Syncfusion Team
August 19, 2020 12:40 PM UTC
Hi Mihaela,
Greetings from Syncfusion.
We have prepared a sample to show the SfBusyIndicator in Splash Screen to achieve your requirement in the Android Platform. Please find the below code snippet and sample for this,
Code Snippet:
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/APP12~1-1190366142.zip
We could not have the Animation in SplashScreen for iOS LaunchScreen. Please check the below,
https://stackoverflow.com/questions/27519195/animating-activity-indicator-on-ios-launch-screen
Please check with the sample and let us know if you have any concern.
Regards,
Rabhia Beham K.
Greetings from Syncfusion.
We have prepared a sample to show the SfBusyIndicator in Splash Screen to achieve your requirement in the Android Platform. Please find the below code snippet and sample for this,
Code Snippet:
| public class SplashScreen : Activity { protected override void OnCreate(Bundle savedInstanceState) { base.OnCreate(savedInstanceState); LinearLayout linearLayout = new LinearLayout(this); linearLayout.Orientation = Orientation.Vertical; linearLayout.LayoutParameters = new ViewGroup.LayoutParams(500, ViewGroup.LayoutParams.MatchParent); linearLayout.SetBackgroundColor(Android.Graphics.Color.White); SfBusyIndicator busyIndicator = new SfBusyIndicator(this); ImageView imageView = new ImageView(this); imageView.SetImageResource(Resource.Drawable.user); imageView.LayoutParameters = new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MatchParent, 50); busyIndicator.AnimationType = Com.Syncfusion.Sfbusyindicator.Enums.AnimationTypes.Ball; busyIndicator.LayoutParameters = new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MatchParent, 100); busyIndicator.TextColor = Color.Red; busyIndicator.IsBusy = true; linearLayout.AddView(imageView); linearLayout.AddView(busyIndicator); SetContentView(linearLayout); Xamarin.Forms.Forms.Init(this, savedInstanceState); System.Threading.ThreadPool.QueueUserWorkItem(o => LoadActivity()); void LoadActivity() { System.Threading.Thread.Sleep(10000); // Simulate a long pause RunOnUiThread(() => StartActivity(typeof(MainActivity))); } } } |
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/APP12~1-1190366142.zip
We could not have the Animation in SplashScreen for iOS LaunchScreen. Please check the below,
https://stackoverflow.com/questions/27519195/animating-activity-indicator-on-ios-launch-screen
Please check with the sample and let us know if you have any concern.
Regards,
Rabhia Beham K.
MP
Mihaela purav
August 21, 2020 02:58 PM UTC
Thank you :)
RB
Rabhia Beham Kathar Mideenar
Syncfusion Team
August 24, 2020 09:39 AM UTC
Hi Mihaela,
Thanks for the information.
We would like to let you know that we also could achieve like your last mentioned update with SfBusyIndicator in one page and navigating to the other page as per your requirement. It will be more as the SplashScreen requirement without being defined in the LaunchScreen.
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/BusyIndicatorSample-593458841
Please check with the above and let us know if you have any concerns.
Regards,
Rabhia Beham K.
Thanks for the information.
We would like to let you know that we also could achieve like your last mentioned update with SfBusyIndicator in one page and navigating to the other page as per your requirement. It will be more as the SplashScreen requirement without being defined in the LaunchScreen.
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/BusyIndicatorSample-593458841
Please check with the above and let us know if you have any concerns.
Regards,
Rabhia Beham K.
Marked as answer
MP
Mihaela purav
August 24, 2020 04:06 PM UTC
Nice idea but maybe it load not very faster before user see indicator.
Best regards
RB
Rabhia Beham Kathar Mideenar
Syncfusion Team
August 25, 2020 04:07 AM UTC
Hi Mihaela,
Thanks for the response.
We would like to let you know that we have provided manual delay using Task.Delay in the AnimatePage. Please use the desired delay to achieve your requirement.
Please let us know if you have any concerns.
Regards,
Rabhia Beham K.
Thanks for the response.
We would like to let you know that we have provided manual delay using Task.Delay in the AnimatePage. Please use the desired delay to achieve your requirement.
Please let us know if you have any concerns.
Regards,
Rabhia Beham K.
SIGN IN To post a reply.
- 5 Replies
- 2 Participants
- Marked answer
-
MP Mihaela purav
- Aug 18, 2020 10:47 PM UTC
- Aug 25, 2020 04:07 AM UTC