• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps adding a switch functionality

chris33

Lurker
Hi i am new to App developing and Android Studio so i would love a response on my question.
I want to add a switch in my app with the logic that the app will start as Offline and manual switched to online.
I have added the switch code but i don't know how to edit the function for it.

Regards
 
Hi i am new to App developing and Android Studio so i would love a response on my question.
I want to add a switch in my app with the logic that the app will start as Offline and manual switched to online.
I have added the switch code but i don't know how to edit the function for it.

Regards

Sorry Chris, was gonna reply but I'm also a noob on this site and to Android and messed up my reply.

http://www.mysamplecode.com/2013/04/android-switch-button-example.html
 
Last edited:
Hi i am new to App developing and Android Studio so i would love a response on my question.
I want to add a switch in my app with the logic that the app will start as Offline and manual switched to online.
I have added the switch code but i don't know how to edit the function for it.

Regards

The requirement makes no sense. "start as Offline" - does this mean the device has no access to wifi or 3G data? Your app has no control over this state when it starts up.
Please clarify, and if possible post your code so we know how far you've got with this, and are able to suggest modifications.
Thanks.
 
Back
Top Bottom