Migrate Xamarin SDK from 3.3.2.5 to 3.8.0

Replace SDK in shared project

  1. Right-click on the Shared Project's References item and select Add Reference....
  2. Select the .Net Assembley tab.
  3. Uncheck IBMMobilePush.Forms.dll.
  4. Click the Browse button and locate the AcousticMobilePush.Forms.dll downloaded from the 3.8.0 package.
  5. Select OK.
  6. Replace all references to IBMMobilePush with AcousticMobilePush.
  7. Change all references to mailingId to use type double? instead of string.

Replace SDK in android project

  1. Right-click on the Android Project's References item and select Add Reference....
  2. Select the .Net Assembly tab.
  3. Uncheck IBMMobilePush.Droid.dll and IBMMobilePush.Forms.dll.
  4. Click the Browse button and locate AcousticMobilePush.Droid.dll and AcousticMobilePush.Forms.dll downloaded from the 3.8.0 package.
  5. Select OK.
  6. Right-click IBMMobilePush.Forms.Droid.cs in the Android project and click Remove.
  7. Right-click the project, click Add and then Existing Files....
  8. Locate AcousticMobilePush.Froms.Droid.cs downloaded from the 3.8.0 package.
  9. Select OK.
  10. Replace all references to IBMMobilePush with AcousticMobilePush.
  11. Edit AndroidManifest.xml
  • Set android:name attribute to co.acoustic.mobile.push.sdk.api.MceApplication
  • Set android:name attribute to co.acoustic.mobile.push.sdk.db.Provider
  • Set the with android:name attribute com.ibm.mce.sdk.notification.NotifActionReceiver to co.acoustic.mobile.push.sdk.notification.NotifActionReceiver instead
  • Set the with android:name attribute com.ibm.mce.sdk.wi.AlarmReceiver to co.acoustic.mobile.push.sdk.wi.AlarmReceiver instead
  • Set the with android:name attribute com.ibm.mce.sdk.session.SessionTrackingIntentService to co.acoustic.mobile.push.sdk.session.SessionTrackingIntentService
  • Remove the node with android:name attribute com.ibm.mce.sdk.fcm.FcmMessagingService
  • Set the with android:name attribute com.ibm.mce.sdk.fcm.FcmInstanceIdService to co.acoustic.mobile.push.sdk.messaging.fcm.FcmMessagingService
  • Set the with the android:name com.ibm.mce.sdk.events.EventsAlarmListener to co.acoustic.mobile.push.sdk.events.EventsAlarmListener
  • Set the with the android:name com.ibm.mce.sdk.registration.PhoneHomeIntentService to co.acoustic.mobile.push.sdk.registration.PhoneHomeIntentService
  • Set the with the android:name com.ibm.mce.sdk.registration.RegistrationIntentService to co.acoustic.mobile.push.sdk.registration.RegistrationIntentService
  • Set the with the android:name com.ibm.mce.sdk.attributes.AttributesQueueConsumer to co.acoustic.mobile.push.sdk.attributes.AttributesQueueConsumer
  • Set the with the android:name com.ibm.mce.sdk.job.MceJobService to co.acoustic.mobile.push.sdk.job.MceJobService
  1. If you're using the Location Features Edit AndroidManifest.xml
  • Set the <receiver> with android:name attribute com.ibm.mce.sdk.location.LocationUpdateCaller to co.acoustic.mobile.push.sdk.location.LocationUpdateCaller
  • Set the <service> with the android:name com.ibm.mce.sdk.location.LocationRetrieveService to co.acoustic.mobile.push.sdk.location.LocationRetrieveService
  • Remove the <service> with the android:name com.ibm.mce.sdk.location.GeofenceIntentService
  • Add a node to the <application> node: <receiver android:name="co.acoustic.mobile.push.sdk.location.GeofenceBroadcastReceiver" android:enabled="true" android:exported="true" />
  • Add a node to the <application> node: <receiver android:name="co.acoustic.mobile.push.sdk.location.LocationBroadcastReceiver" android:enabled="true" android:exported="true" />
  • Set the <service> with the android:name com.ibm.mce.sdk.location.LocationEventsIntentService to co.acoustic.mobile.push.sdk.location.LocationBroadcastReceiver
  • Set the <service> with the android:name com.ibm.mce.sdk.location.LocationSyncAlarmListener to co.acoustic.mobile.push.sdk.location.LocationSyncAlarmListener
  • Set the <service> with the android:name com.ibm.mce.sdk.beacons.MceBluetoothScanner to co.acoustic.mobile.push.sdk.beacons.MceBluetoothScanner
  • Set the <service> with the android:name com.ibm.mce.sdk.beacons.BeaconsVerifier to co.acoustic.mobile.push.sdk.beacons.BeaconsVerifier
  1. If you're using the Snooze Plugin Edit AndroidManifest.xml.
  • Set the with the android:name com.ibm.mce.sdk.plugin.snooze.SnoozeIntentService to co.acoustic.mobile.push.sdk.plugin.snooze.SnoozeIntentService
  1. If you're using the Inbox Plugin Edit AndroidManifest.xml.
  • Set the with the android:name com.ibm.mce.sdk.plugin.inbox.InboxUpdateService to co.acoustic.mobile.push.sdk.plugin.inbox.InboxUpdateService
  1. Double click on the Android Project.
  • Select the General tab, make sure the target framework is Android 9.0 Pie.
  • Select the Android Application tab, make sure the Target Android version is Android 9.0 (API level 28).
  1. Right-click on the Packages of the Android Project, tap Update.

  2. Right-click on the Packages of the Android Project, tap Manage NuGet Packages.

  3. Right-click CustomMapRenderer.cs and click Remove.

  4. Right-click Android project and click Add then Existing Files... select samples/Sample/Droid/Custom Controls/CustomMapRenderer.cs from 3.8.0 Package.

  5. Change all references to mailingId to use type double? instead of string.

Replace SDK in iOS project

  1. Right-click on the iOS Project's References item and select Add Reference....
  2. Select the .Net Assembly tab.
  3. Uncheck IBMMobilePush.iOS.dll and IBMMobilePush.Forms.dll.
  4. Click the Browse button and locate AcousticMobilePush.iOS.dll and AcousticMobilePush.Forms.dll downloaded from the 3.8.0 package.
  5. Press OK.
  6. Right-click IBMMobilePush.Forms.iOS.cs in the iOS project, click Remove.
  7. Right-click the project, click Add and then Existing Files....
  8. Locate AcousticMobilePush.Froms.iOS.cs downloaded from the 3.8.0 package.
  9. Press OK.
  10. Replace all references to IBMMobilePush with AcousticMobilePush.
  11. Change all references to mailingId to use type double? instead of string.

Dark mode support

In order to support Dark Mode on iOS 13+ and Android 10+, it is recommended that you use a DynamicResource with two custom themes. This requires two XAML files, one for each theme as well as an <color> node for each globally defined color. Each XAML element is then modified to refer to the globally defined colors for their interface elements' foreground and background colors as needed.

See the sample app for examples of how this works in practice.

Android support

In addition, in Android, you'll need a custom page renderer that selects the correct theme for the current situation. See the Sample app for examples of how this works in practice.

iOS support

iOS will also need a custom page renderer that selects the correct theme for the current situation. See the Sample app for examples of how this works in practice.


Did this page help you?