[4.7, 4.6.1] Problems including headers to dependency build.cs

Hello, I am unable to include “Networking” and / “Sockets” to the dependency module names.

I did this on a fresh third person C++ code project:

PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "Networking", "Sockets" });

after I did this I rebuild the system by using VS that I would be able to use:

 #include "Networking.h"
    #include "Sockets.h"

in my code.

I am only able to use the classes like:

 #include "Runtime/Sockets/Public/Sockets.h"
  #include "Runtime/Networking/Public/Networking.h"

for example.

Did you already check if the header’s directory is included in the project settings include directories?

If you are using VS2013, maybe also try to check VC++ directories in your project’s propierties and in the source directories check “Inherit from parent or project defaults”.

Hi 3HMonkey,

I tried reproducing the issue that you described in 4.6.1, 4.7.0, and 4.7.2. In all three of my test projects I was able to build the project successfully in Visual Studio. Could you provide some additional information about this issue?

  • Are you using the binary version of the Editor installed by the Launcher, or did you build the Engine from source code?
  • What file(s) are you adding your #include lines to?

Well, I found the solution I didn’t know. I had to regenerate the VS project’s files over the windows explorer by rightclicking the *.uproject file.

adding some notes i found myself :

  • use Engine.h instead of EngineMinimal.h
  • i have VS2013 and then updated to engine 4.10 and had to download VS2015 but when opening a uproject it would be opening with VS2013 , i had to change defaul app for opening solutions
  • keep UE editor open before “regenerate the VS project’s files” otherwise uproject can become corrupt and wont let open the project , i think keeping UE editor open, keeps a lock on the project/BInaries/Win64/project.dll that the editor uses so its not rebuilded hence not corrupted

after doing this steps i got intellisense happy with the include “Networking.h” and project builds
im new to UE4 so its posible im wrong on some points so please comment