Given that it's in your onCreate of the main activity, I'd say it's sent
every time onCreate is called on your main activity, unless you've added
additional logic you're not showing.

On Thu, May 17, 2012 at 3:02 AM, Eyal Berman <bermane...@gmail.com> wrote:

> in my onCreate of the main avtivity i put that code
>
> Intent registrationIntent = new
> Intent("com.google.android.c2dm.intent.REGISTER");
> registrationIntent.putExtra("app", PendingIntent.getBroadcast(this, 0, new
> Intent(), 0)); // boilerplate
> registrationIntent.putExtra("sender", "bermane...@gmail.com");
> startService(registrationIntent);
>
> i add the reciver to manifest.xml
>
> <receiver
>             android:name=".MyC2dmReceiver"
>             android:permission="com.google.android.c2dm.permission.SEND" >
>             <intent-filter>
>                 <action
> android:name="com.google.android.c2dm.intent.RECEIVE" />
>                 <category android:name="com.xxxxxx.testc2dm" />
>             </intent-filter>
>             <intent-filter>
>                 <action
> android:name="com.google.android.c2dm.intent.REGISTRATION" />
>                 <category android:name="com.xxxxxx.testc2dm" />
>             </intent-filter>
>         </receiver>
>
> i try to send the registrationID to my server
> when it's send? just in the first time (installation ) or every time the
> app is loadded?
>
>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to