NotificationCompat.Builder缺少的build()方法 [英] NotificationCompat.Builder missing build() method

查看:122
本文介绍了NotificationCompat.Builder缺少的build()方法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想这样做完全是,他所做的: Android的通知的时间 但在我AlarmReceiver课,我有一个错误:该方法生成()是未定义的类型NotificationCompat.Builder,在行:mNotificationManager.notify(1,mBuilder.build());

I want to do exactly, what he does: Android Notification at time But in my AlarmReceiver class, I have an error: The method build() is undefined for the type NotificationCompat.Builder, at line: mNotificationManager.notify(1, mBuilder.build());

在Android开发者网站是一个类似code,但同样的错误出现(的 http://developer.android.com/training/notify-user/build-notification.html )。

In android developer site is a similar code, but the same error appears(http://developer.android.com/training/notify-user/build-notification.html).

任何帮助是极大的AP preciated。

Any help is greatly appreciated.

推荐答案

您可能对Android的支持包的旧版本。确保您的项目有 Android的支持 - v4.jar Android的支持 - v13.jar 在库/

You may be on an older version of the Android Support package. Make sure that your project has a current copy of android-support-v4.jar or android-support-v13.jar in libs/.

这篇关于NotificationCompat.Builder缺少的build()方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆