broadcastreceiver

Why doesn't my BroadcastReceiver receive broadcasts from another app?

App A has this BroadcastReceiver in its manifest (within <application>): And this receiver: public class RemoteControl extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { Log.w(TAG, "Look what I did!"); } } I'm trying to trigger this from App B: public void onClic...

Android-Broadcast Receiver and Intent Filter

Hi, I am new to android platform.please help me out how the Broadcast Receiver and Intent Filter behaves in android.please explain in simple line or with example.thanks in advance... ...

Error starting conversation list activity from broadcast receiver on deveice

I've got a broadcast receiver that gets triggered when a notification my app created is clicked. When that broadcast receiver is started it completes a task then tries to bring of the sms conversations. It works fine on the emulator, however when I try it on a droid incredible it crashes with the following message 07-07 22:57:23.901: ...

how to to pop up and ask for user input on android after receiving broadcast

hey, im new to android development and trying to make my first application. What im trying to implement is a feature i've seen in Handcent SMS: the popup notification. So far, my application has a broadcast receiver that uses Toast to display an incoming SMS message. However, instead of a Toast notification, I want to make a pop up wi...

Android Best Practice on Updating the UI from BroadcastReceiver to a certain activity

When i have a broadcastReceiver say android.intent.action.MEDIA_BUTTON and i want to update the current activity's UI without creating a new activity, is there any good practice on this one? What i know (might not be correct) 1) I can put the BroadcastReceiver in the same class as the activity and call the updateUI function after certa...

How to receive broadcasts of RINGER_MODE_CHANGED_ACTION

I have the following broadcast receiver: public class MyRingModeReceiver extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { Logger.iLog("In my Receiver"); } } I then have a service that onCreate does the following: IntentFilter filter = new IntentFilter(); filter...

Android, Detect when other apps are launched

Hi I'm trying to develop an app that prevents a user from getting to a specified app without a password. The scenario is... user clicks on "Email" app (for example) my app detects launch of an app my app confirms it is the "Email" app my app opens a view over the top, asking for a password user enters a password, if correct, my app dis...

Respond to Intent.ACTION_BATTERY_CHANGED

How can I setup an method to be called whenever Intent.ACTION_BATTERY_CHANGED is raised? Do I have to subclass BroadcastReciever? Or can I use a method to hook up the action to a method. ...

set 2 proximity alerts with the same broadcast

Hi, I create a proximity alert in this way private void setProximityAlert(float radius, double lat, double lng, String place) { long expiration = -1; LocationManager locManager = (LocationManager) getSystemService(Context.LOCATION_SERVICE); Intent intent = new Intent(TREASURE_PROXIMITY_ALERT); intent.putExtra("lat", ...

How to create a new Intent for another app's broadcast receiver?

In the examples, they create Intent as: Intent intent = new Intent(this, AlarmReceiver.class); But suppose my AlarmReceiver class is in another app, how do I create this intent? I've tried with new Intent("com.app.AlarmReceiver") but nothing happens.. It was not called.. Any idea? --Broadcast definition added using the manifest ...

Strange problem with broadcast receiver in Android

Hello, I have just this piece of code which is quite simple. I have a list and in the onCreate method I added some objects to this list to show them on the screen. I have a broadcast receiver which has to enable/disable some elements of the list when there aren't internet connection. The broadcast receiver works good if the connection...

Android - Sending data from an activity to a service

I've a local service that is started in my main activity. The service is responsible for network I/O. It also interacts with other activities in my application. Till, now the service was only "providing" data to activity (using callbacks and not Intents.) Now I need to send data (custom objects) from my activities to the service. I unde...

iPhone reading a broadcast transmission

Hi everybody, I have a server that should send a broadcast transimission, which I have to read in an iPhone App. I searched in the net, but I didn't find anything. I'm able to play a video starting from its URL, so my question is: how can I play in my iPhone a broadcast transmission? ...

android intent for sdcard ready

I have an application that uses a file on the SD card, the application runs when the phone boots, and it has become apparent that the file cannot be accessed when the program is first run as it starts working before SD card is avaliable. Is there an broadcast receiver I can use to tell when the SD card is ready? Update Just to summar...

AlertDialog in BroadcastReceiver

I'm trying to create an application that can use the android as a fax machine, IE Send a picture as a fax or receive a fax and save as a picture. So far I'm starting from the ground up and making sure I can intercept a call at the users discretion. I have an Receiver registered in the Manifest of my program with a filter of Phone_State w...

Android Alarm Manager with broadcast receiver registered in code rather than manifest

Hi, I want to use an alarm to run some code at a certain time. I have successfully implemented an alarm with the broadcast receiver registered in the manifest but the way i understand it, this method uses a separate class for the broadcast receiver. I can use this method to start another activity but I cant use it to run a method in m...

Android : Receive custom broadcast when a button in a widget is clicked

I have a BroadcastReceiver that works fine, i.e. executing this code from an Activity, the receiver receives the intent: Intent toggleIntent = new Intent(this, ToggleServicesReceiver.class); this.sendBroadcast(toggleIntent); But I am trying to do the same from a button in a Widget: public void onUpdate(Context context, AppWidgetManag...

Problem acquiring wake lock from broadcast receiver

Hi I have a problem. I am trying to make a broadcast receiver acquire a wake lock so my alarm will wake the phone from sleep mode. In the broadcast receiver below, the program crashes with "source not found" on line "sCpuWakeLock.acquire(); when the class "AlarmAlertWakeLock" is called by AlarmReceiver. Any idea what's going on? Is th...

Android : Check phone number present in Contact List ? (Phone number retreive from phone call)

Hello I make a BroadcastReceiver to receive Phone number of the person who call me <intent-filter> <action android:name="android.intent.action.PHONE_STATE" /> </intent-filter> 1/How to check if the phone number receive is on my contact list ? Do you have a tip to know if this phone number exist on contact list with out loading con...

Android Listen for/Detect entry into the log

Is it possible to listen for entries to the log? Ie is there a broadcast intent for when a log entry is appended? ...