OpenHarmony开发者论坛
标题:
启动UIAbility时报错:must have required property 'startWindowIcon'
[打印本页]
作者:
xiagengwen
时间:
2023-8-31 19:21
标题:
启动UIAbility时报错:must have required property 'startWindowIcon'
[md]【问题描述】复制别人的代码到IDE运行,启动UIAbility时报错:must have required property 'startWindowIcon',报错如图,如何解决?
![f91958f3-dc6e-42d0-b66d-a039e95703ca.png](data/attachment/forum/202308/31/192151hllssvlzr571rrfn.png "f91958f3-dc6e-42d0-b66d-a039e95703ca.png")
【运行环境】
硬件:rk3568; ROM: 3.2 Beta5; API 9
[/md]
作者:
马迪
时间:
2023-9-5 10:16
看报错信息,像是UIAbility配置中缺少startWindowIcon属性配置,需要在module.json5中abilities中配置startWindowIcon。
{
"module": {
// do something
"abilities": [{
// do something
"startWindowIcon": "$media:space",
"startWindowBackground": "$color:white",
}]
}
}
复制代码
可以参考资料:Stage模型配置文件
https://gitee.com/openharmony/do ... nfiguration-file.md
欢迎光临 OpenHarmony开发者论坛 (https://forums.openharmony.cn/)
Powered by Discuz! X3.5