Is there any possible way to control a Dialog in Android from remote server? Let say I have an application and there I created an If Statement. For example: When the number 2 is not equal the number in my remote server, the Dialog should pop out in my application. Is there any simple way to accomplish this? Please guide me, thanks in advance!
Good Question.
First of all to implement push server mechanism before android 2.2 you need to implement a novel workaround. The idea is to invoke a intent. One way to do is to register a broadcast receiver for an event (eg: receiving sms message) , check for the format of the message and invoke the corresponding Intent. ( which will invoke the dialog or you might use Notification).
But if you are using android 2.2 and above, you are lucky. Google introduced Cloud To Device Messaging Framework. Check this link.
Related
I am currently developing an app which sends notifications at specific hours of the day. I can create an intent service, but I dont think it would work when the user is outside the app. So I need a service which works at specific times
Try to look here, I was using Firebase in my projects and it is super easy to implement...
I want to make an android app. in this app i want to control all the functionality from my website.t like if i click on a button from my website then it trigger my app and start a service from website.
last few days i spent lots of time to search the answer of my question if anyone can help me then please tell me the process how to do this...
You can do this with GCM
Steps:
Create admin panel with your requirements.
Register your app for GCM.
When certain action is performed then push the GCM.
Your app automatically received this GCM.
You can pass custom keyvalued json with GCM.
So according to this perform operation in your app.
Your app receive GCM even app has been killed so in background.
PS: you can also use FCM.
Link for GCM
Link for FCM
Tell me if you face any probelm in this.
maybe one way is when you click on button some dummy file with specific Extension (like .egn ) downloaded and try to opened. also register your Activity To Open that kind of files.
Register Activity To Open Any File With Certain Extension
I didn't test this solution but logically it is posible.
You will have to make a custom connection from your device to the website and when the button is clicked you have to store this on the server, let the code handling your device connection then check for this data and send it on to the device, which will have to actively process the data coming from the connection you established to the server and then have the App react appropriately.
It will take a lot of custom connection handling to make this possible.
I am developing a POC Message client in Android. This app mimics a messaging application, there is no server interaction. The application starts a new chat with a random user. I want to use Broadcast receiver & message object ( as in a real application ). As there is no server interaction, I want to create a Broadcast sender part in this app, which should randomly generate some messages; My app receives these messages through Broadcast receiver, process the message & show on UI. So, while demoing, it looks like a real messaging app.
If any one knows a simulator engine app in Android which I can use instead of developing a broadcast sender inside my app, Please let me know.
Or, if any one can suggest some better idea for implementing a mimic messaging application, please advise. Thanks in advance.
You can create a service for your app which will always listen on ACTION/signal/message you want. It will activate your app if it gets specific message. And it will run always in the background so that user will never notice it. Hope this will give you a hint.
Is there any possibility to trigger an action on Android?
Like if we send a message to an android phone, it should execute some instruction, like running an app or something.
Is it possible with Android? Or iOS?
Or can the event be anything like reception of an email or phone call from a specific number or anything that can be done remotely?
Something as shown in the link here. But I want to know how to program these triggers.
Can someone help me out, please?
I want to manipulate the network settings so that it can automatically switch on the Wi-Fi or data and send back some data. Is that possible?
Yes you can trigger an action on android.
For that, you need to use a broadcastreceiver (here is a good article about how to use it http://www.vogella.com/articles/AndroidBroadcastReceiver/article.html)
Here is a simple example of the source code in order to display a message to the user when a sms is received.
http://androidsourcecode.blogspot.ch/2010/10/receiving-sms-using-broadcastreceiver.html
Prior to posting this query here, I have gone through a similar requirement by a user in the post here
Based on research, what I understand is, push notification concept can be used to notify the application of any changes happening in the server, if and only if, the server control rests with us.
I have made an application which would display the data from a mobile website. Is there a way out by which I can notify the handset user of any change happening in the server, such that the user gets an alert in his handset, so that he can open the application and see what is the new addition/change that has occurred in the website, when I have no control over the server? Pardon me , if I sound totally dumb with this question. Had such a requirement and was curious to know the way out, if any.
This way you should build your own web service which will poll other service for changing and then push alert to android device via Google Cloud Messaging for Android (GCM).
But you also can poll this service with your own application in background service. This method is very bad because of battery drain and network connection using, but this is no need for 3rd party services
try noczone.com, they have custom notification service with an easy to use PHP sdk
https://noczone.com/?page=custom_alerts_sdk
i use it to let me know whenever i receive a support ticket or any new registrations.
and you will need to have their app installed to receive notifications on it
https://play.google.com/store/apps/details?id=com.wr.noc