当前位置:网站首页>Ue4/5 cannot open the file "xxx.generated.h" (cannot open file xxx.generated.h) solution summary
Ue4/5 cannot open the file "xxx.generated.h" (cannot open file xxx.generated.h) solution summary
2022-07-24 06:59:00 【Zero one_】
Unable to open xxx.generated.h yes UE One of the common problems in development , Sometimes people scratch their heads . This paper will summarize the author's various methods to solve this kind of problem in actual development , New methods will be added here in the future .
Method 1 , Delete Intermediate Folder , And regenerate
The first solution is to delete Intermediate Folder , Reuse uproject File generation VS Engineering documents (Generate Visual Studio project files). It should be noted that ,Intermediate The folder is not only in the main project directory , There are also in the directories of various plug-ins .xxx.h Which directory does the file belong to , We will delete the directory Intermediate Folder .


We know , Various xxx.generated.h By UHT(Unreal Header Tool) Generated , And keep it in Intermediate Folder . Delete Intermediate Folder ,UHT Will regenerate generated.h file . So this method is effective .
Method 2 , Delete all generated files , Regenerate
UE In the engineering catalogue , Some files and folders are automatically generated by the system . In the following two figures , We highlighted these files , Also, don't forget that there are these files in the plug-in .


Delete .vs Folder 、Binaries Folder 、Intermediate Folder 、Saved Folder 、sln file , Not only can it solve xxx.generated.h The file cannot be opened , It can also solve other difficult and miscellaneous diseases . But here's the thing , In the delete Binaries Folder time , Be sure not to use it dll When the third-party library is deleted , Otherwise, the following problems will occur .

Method 3 : Adjust module dependencies
If there are multiple modules in the plug-in , If the dependencies of these modules are not set correctly , It can also lead to xxx.generated.h Problems that cannot be opened . As shown in the figure below , Suppose the same plug-in , There are two modules AA and BB, And the module AA rely on BB. If in the module AA Of Build.cs There is no setting for BB Dependence ( As shown on the left in the figure below ), Or put it right BB The dependence of is written in PrivateDependencyModuleNames in ( As shown in the right figure in the following figure ), It will also lead to such problems .


Use the two settings above , Will lead to the following “ Can't open file ‘xxx.generated.h’” The problem of , The solution is in PublicDependencyModuleNames To the module BB Dependence . Here's an explanation PublicDependencyModuleNames and PrivateDependencyModuleNames The difference between : Dependent on modules AA Other modules of , Such as the main file directory , Only its PublicDependencyModuleNames Modules exposed in , Cannot access PrivateDependencyModuleNames Modules declared in .

边栏推荐
- PyQt5入门——学生管理系统
- MySQL gets the self incrementing line mark (different from MySQL version)
- 一个AI玩41个游戏,谷歌最新多游戏决策Transformer综合表现分是DQN的两倍
- (note sorting is not completed) [graph theory: find the shortest path of single source]
- 济南人社已签1W+电子劳动合同,法大大助力HR数字化
- Metaltc5.0 realizes webrtc version IPC of Junzheng pure C
- Don't care too much about what others think of you
- [lvgl (1)] a brief introduction to lvgl
- lambda表达式对list对象进行多字段排序
- GE口:SGMII模式和serdes模式
猜你喜欢

UE4/5 无法打开文件“xxx.generated.h”(Cannot open file xxx.generated.h)的解决方法总结
![[lvgl (1)] a brief introduction to lvgl](/img/2e/2e155f1d3669c27ad1b090ca954224.png)
[lvgl (1)] a brief introduction to lvgl

安装snownlp包过程出现Requirement already satisfied:及Read timed out.问题解决方法

(笔记整理未完成)【图论:求单源最短路径】

Redis特殊数据类型-HyperLogLog

Sparksql core usage, 220724,
![[lvgl (important)] style attribute API function and its parameters](/img/55/f25a510cf04caff7ee15e72360c3a1.png)
[lvgl (important)] style attribute API function and its parameters
![[lvgl layout] grid layout](/img/36/47f586f3dc1a114ed7775c4e190872.png)
[lvgl layout] grid layout

owasp top10 渗透测试

华为专家自述:如何成为优秀的工程师
随机推荐
Redis特殊数据类型-HyperLogLog
别太在意别人的眼光,那会抹杀你的光彩
tensorflow einsum函数
MGR_ mysqlsh_ Keepalive high availability architecture deployment document
Introduction to kubernetes (kubernetes benefits)
Redis基本类型-哈希Hash
[audio decoding chip] Application of vs1503 audio decoding chip
Requirements already satisfied: and read timed out. problem solving methods appear during the installation of snownlp package
MapReduce(一)
[learning notes] see the difference between a+++a and a+a++ from the compilation
Nodejs enables multi process and inter process communication
[lvgl (6)] display Chinese settings and make Chinese font
三级分类/菜单的查询——树形结构
Special effects - cobweb background effects
Redis data type -string (string type)
Detailed analysis of the process (life cycle) of class loading
sojson jsjiami.com. V6 crawler JS reverse
mysql获取自增行标(区别mysql版本)
一日一书:机器学习及实践——从零开始通往kaggle竞赛之路
Thinking of data analysis -- analyzing the retail industry as a whole -- an all-round and multifaceted detailed analysis