I am developing a real time chatting application in which i use QuickBlox demo. When user one and user tow both r on-line it works fine but when one user is of-line and some one sending a message to this user(of-line) user he doesn't get any message or notification when he come back on-line.
Can any one suggests me how to sent push notification in quickblox.
I think you should learn this carefully it defiantly work.
http://quickblox.com/developers/SimpleSample-messages_users-android
Related
I've been searching in a couple of topics here about this matter but I can't seem to get it right for Java.
QUESTION:
How can I send a message from my bot without the enduser having to start any conversation or have any kind of interaction?
If you use C#, you Can use telegram.api and below code:
bot.sendMessage.send(bot.chat_id,"Your Message").ToString();
I have been poking around to figure out how to do this with Service or Activity, or Broadcast Receiver and I can't seem to get a definitive answer.
I want to be able to write the following data event(s) with timestamp to a file with an application that is running in the background.
Power button pressed on
Call being sent outgoing
SMS message being sent outgoing
It is an application that I am attempting to build for logging phone usage with the timestamp written to a file.
Went through many explanations and this is the only one that seemed to make sense:
https://thinkandroid.wordpress.com/2010/01/24/handling-screen-off-and-screen-on-intents/
Any information or tutorials on this would be greatly appreciated.
I would do the following:
Create a broadcast receiver that based on the intent received determines the type of event. Have a look to the Command design pattern.
The command launches a new intent using the Broadcast receiver as a Context.
Create a service that is able to handle this intent, so it starts, sends some data or stores it wherever, and shutsdown. Have a look to the IntentService class.
Create an activity to show the content you have stored or to explain the user what your app does.
We're developing special devices that uses XMPP to talk to each other. A new API i am developing now, should talk to these devices too. The problem i am facing - all these devices are building little groups - for each customer we have... so we will have a chat-room for each group of devices, or, for each of our customer with his bunch of devices ;)
But now.. the api should be able to talk to every device that is connected. I don't need a real broadcast-mechanism - in the end, i will send a message only to one specific device..
But i don't want to login to each chat-room either - running a product with over 40k customers and much more devices, will end in a funny api, that is opening over 40k chat-rooms at startup... even if don't tried this yet, i can't imagine that an app like this will run well... even though we can have millions of customers in a few years.. i don't like solutions that will grow linear with the amount of customers, if you know what i mean :/
Now, basically i'm thinking of a solution, where i just can use the basic XMPPConnection to do my stuff.
MyCustomMessage msg = new MyCustomMessage();
msg.setTo("*"); // don't know what to address, i want to send it to "all"
msg.setFrom("ThatAPI"); // just a string telling that is sent from my java api ;)
msg.setEvent(event); // stuff that is coming through the parameters of the method where this code is inside
msg.setCustomStanza(data); // same here
connection.sendPacket(msg); // my try to send it to all till now..
Somewhere in the Ignite Realtime Forums i have read of one guy who "solved" it, but everything he says is "it's working now, i push my message through the sendPacket of Connection"... ok nice, my attempt of this seems not to work :(
Any better ideas/real implementations how this will work fine?
Basically i start to think that XMPP will not be the best technology to achieve something like this at all - i wish i could have a real/basic socket-implementation where something like this would be piece of cake.. But i can't choose - the third-party-system has implemented XMPP already... not enough time to change all of this... Just if you're wondering why we try this on XMPP..
You seem to have some conflicting requirements in that you want to send to all devices now, but only 1 specific device later. Are both models required at the same time, or do you plan on switching? How either is done would be different solutions.
As for your current approach, I think pubsub would make more sense than your chatroom approach, as that is oriented to generic message passing to subscribers.
You could set up a pubsub node per customer to send messages to all
of their devices.
As for a broadcast to all, you can make all devices
subscribe to a single pubsub node.
Thus you control broadcast and group messages by sending to the appropriate pubsub node.
For sending to a specific device, that is just a sendPacket to the specific entity, nothing really special there.
I'm trying to develop an application that allows users to chat with each other via sms..
I created an activity that sends and receives sms, but I don't know how can I make their chatting moving up (as in SMS messages in iPhone it seems like chatting page),
All I did is make the msg in edit text and receives it in textview ...
actually i don't know what's the name of this thing to make search ...
can anyone inform me what's the name of this technique!!!
I'm really confused ='.
What I would probably do in your case is implement the chat history as a ListView, sorted by entry timestamp. When you send or receive new messages, just add them via your ContentProvider and tell the ListView to scroll to the bottom position. It's a more code, but examples exist, and it's more flexible than hacking up a TextView.
I need information about getting new letters from my gmail mailbox: i turn on synchronization on my device, and when my mailbox get a new letter gmail client on my device will respond to it and show me notification. How does it work? Gmail client sends requests every second/minute or there is mean to respond to this event? I need it, because i have been making application which must respond to a new event in Google Calendar. Thank you.
Try this.
Might be helpful, I was trying something similar....