I’m having a strange problem and Im not sure how to proceed. When I try building my project in Visual Studio, I get the following error:
Error MSB3075: The command E:\Unreal Engine - Git\Engine\Build\BatchFiles\Rebuild.bat MyGameEditor Win64 Development E:\Unreal Harddrive\MyGame\MyGame.uproject MyGame C:\ProgramFiles(x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.MakeFile.Targets
When I try to run Rebuild.bat by itself (with commands) I get:
Microsoft Windows [Version 6.3.9600]
(c) 2013 Microsoft Corporation. All rights reserved.
C:\Windows\system32>E:\Unreal Engine - Git\Engine\Build\BatchFiles\Build.bat E
picSpaceOnlineEditor Win64 Development E:\MyGame\MyGame.uproject -waitmutex
Creating makefile for MyGameEditor (no existing makefile)
Performing full C++ include scan (no include cache file)
Building UnrealHeaderTool...
Target is up to date
Parsing headers for MyGameEditor
Running UnrealHeaderTool E:\MyGame\MyGame.uproject E:\MyGame\Intermediate\Build\Win64\MyGameEditor\Development\UnrealHeader
Tool.manifest -LogCmds=loginit warning, logexit warning, logdatabase error -Unattended -WarningsAsErrors
E:/MyGame/Source/MyGame/ProjectVersionBlueprint.h(17) : LogCompile:Error: Remapping old metadata key FriendlyName to new key DisplayName, please update the declaration.
Error: Failed to generate code for MyGameEditor - error code: OtherCompilationError (5)
UnrealHeaderTool failed for target MyGameEditor (platform: Win64, module info: E:\MyGame\Intermediate\Build\Win64\MyGameEditor\Development\UnrealHeaderTool.manifest).
C:\Windows\System32>
The error appears to be referring to line 17 of the ProjectVersionBlueprint.h file. If you see “FriendlyName” on that line can you instead change it to “DisplayName” (or the other way around if you see DisplayName).
Last night I try to solve this problem and found that though the VS2105 gave the error “Error MSB3075: The command…have sufficient rights to run this command…” , but the actual question was not the “rights problem”.
when I run the command in windows CMD line, the output prompt that some .h file had problem. so the “Error MSB3075:…” may be a compile problem, because the compile failed ,some binary file was not generated , the command could not find them.
Unfortunately that is not enough information for me to understand why the compile is failing. Please post a screenshot of the VS output tab to show what is being reported as the cause for the compile failure.
The OtherCompilationError(5) line above indicates an error without a unique error code. You can find more information about the error if you switch to the Output tab. You should find the OtherCompilationError(5) line there as well and the actual error should be stated a line or two above that.
Hi - not sure if this will help, but I had the same error, with additional errors saying that VS17 cannot get access to certain files. I use Perforce, so I unlocked everything - still no joy. I then went to the file it said it cannot access and Unlocked it (Right-Click file, and uncheck ReadOnly). Still no joy. I then went to the Root folder (the project name folder) and Unchecked -Only, and selected to Uncheck all children folders and files. It worked after that. Not sure why but it seems to be ok now.
If this is a bad way, or just crappy way to fix it, then I would love to hear the correct way to fix it.
Thanks
You don’t have to make your properties public to able to expose them to blueprints. You can encapsulate your data in c++ and still expose them to blueprints by using the meta specifier AllowPrivateAccess on these private variables.
I’m using UE 4.18 and in the list of available meta properties, there is no AllowPrivateAccess property (you can check it out on your own: docs/latest#Valid_Meta_Properties).
But I found this meta there (docs/latest/API)
So, after I adding it to my code it still works well.
Thanks.
But I want to stress on one of the problems which could invoke the error 5.
I just came across the same issue. This started to happen to me after I did an upgrade on Visual Studio 2017 to version 15.7.2. I was able to solve this problem by rebuilding the solution.
Right-click in the solution and click on Rebuild or type Ctrl+Alt+F7.
I spent almost half day to search for the solution to this.Finally, I found something useful.
可以参考一下上面两个问题的答案,其实两个都一样。
You can refer these two links above. Both the same, either one will be fine.
为了方便你们,我直接复制了解决方案:
For your convenient, I copyed it :
This is a known issue with changing to 4.12 and using tasks. It can be resolved by simply adding “GameplayTasks” to the PublicDependencyModuleNames section inside your ‘ProjectName’.Build.cs For example:
PublicDependencyModuleNames.AddRange(new string[] { “Core”, “CoreUObject”, “Engine”, “InputCore”, “AIModule”, “GameplayTasks” });
SIMPLE ANSWER: You most likely declared UPROPERTY() within your header file as private or forgot to make it public since classes members are private by default (hot tip). This I found to be the main issue for most people getting this compiler error.
SIMPLE SOLUTION: Declare public: before writing out your UPROPERTY() or use the “AllowPrivateAccess” property such shown in the example below.