VS does not see online.h, but compiles ok

Hello,
I have a small problem. As you can see on screenshot, the code has compiled, but it says that IOnlineSubsystem is undefined.

Do you have any idea how to resolve the problem?

My ProjectName.Build.cs has:

PublicDependencyModuleNames.AddRange(
   new string[] {
         "Core",
         "CoreUObject",
         "Engine",
         "OnlineSubsystem",
         "OnlineSubsystemUtils",
});

Greetings

http://s27.postimg.org/sn3avdxvl/image.png

Problem Solved.
After adding OnlineSubsystem to PublicDependencyModuleNames I had to Refresh visual studio project.
Inside Editor->File->Refresh Visual Studio Project

You’re a legend for this! Thank you very much!

Worked like a charm, I’ve done all the necessary steps but couldn’t get my project to access the API and this worked!