private void Notify(String notificationTitle, String notificationMessage){
NotificationManager notificationManager = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
@SuppressWarnings("deprecation")
Notification notification = new Notification(R.drawable.logob,"New Message", System.currentTimeMillis());
Intent notificationIntent = new Intent(this,NotificationView.class);
PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, notificationIntent, 0);
notification.setLatestEventInfo(foradmin.this, notificationTitle,notificationMessage, pendingIntent);
notificationManager.notify(9999, notification);
}
試圖生成的應用程序的通知,但我得到的錯誤無法解決setLatestEventInfo()
方法。我想生成的應用程序的通知,但我得到的錯誤無法解決setLatestEventInfo()方法
的可能的複製[無法解決方法setLatestEventInfo(http://stackoverflow.com/questions/32345768/cannot-resolve-method-setlatesteventinfo)? –
actully我想創建時,我在我的項目選擇sendtoapp選項,然後一個通知發送到所有registerd移動沒有在我的數據庫 – sonali
PLZ有人幫我... – sonali