使用notifycationManager.publish时报错“message is Notification is not enabled”

使用notifycationManager.publish时报错:“Failed to publish notification. Code is 1600004, message is Notification is not enabled”。

HarmonyOS
2024-01-30 19:07:04
浏览
收藏 0
回答 1
待解决
回答 1
按赞同
/
按时间
justtouch

应用的通知开关为关闭状态,当通知开关为关闭状态时,方法将返回该错误码。

通知设置里开启应用通知开关。

分享
微博
QQ
微信
回复
2024-01-31 23:29:50
相关问题
使用ohpm发布tgz文件时报错
290浏览 • 1回复 待解决
冷启动报错Error message
789浏览 • 1回复 待解决
拉起UIAbility时报错16000050
934浏览 • 1回复 待解决
app启动crash报错Error message:MainPage:
787浏览 • 1回复 待解决
The Map permission is not enabled
763浏览 • 1回复 待解决
OLED 屏幕输出编译时报错问题
9177浏览 • 2回复 待解决
webview打开地址时报错 怎么回事啊?
4287浏览 • 1回复 待解决
通过USB连接打印机打印小票时报错
65浏览 • 0回复 待解决
hmscore接入安装HarmonyOS的npm包时报错
349浏览 • 1回复 待解决
控件enabled设置为false时,hover失效
931浏览 • 1回复 待解决
HarmonyOS HAR publish时需要的密码问题
276浏览 • 1回复 待解决
ohpm publish 推送har包大小的限制
284浏览 • 1回复 待解决