C++ Beginner issue

I’m just starting out C++ with unreal engine.
I’m trying to simply output a log but it’s giving me this error.
I build fails for some reason but I have no idea why…
I had another UE5 project and for that it works.
I created a new UE5 project but for this one this error pops up.
Please help.

image

image

Why did you put the log command inside the function, as in separate function just for it, it serves no pupose. You are basicly calling a function with a log error to log what ? The log comes after an operation if success … else log line sintax. You have to log something, I would also try it in an actor class first. You also have errors with the image wrapper and there is no image wrapper function in your page. You have no include also with the image wrapper module.
#include “IImageWrapperModule.h”

The syntax for the log looks strange, for example you could try.

if(ImageWrapper.IsValid())
{
UE_LOG(LogTemp, Log, TEXT(“It’s great everything is fine keep going”));

If this is what you are trying to do since I see you got errors with image wrapper. You can also use else and log it with, “it’s not going great” in case it fails.

You have 3 opening brackets and 2 closing brackets in line 13. Fix that;

As for modules: if you include something you’re not really familiar with, go to the official documentation and look it up. In some cases you’ll have to add dependency modules to your build.cs file. I don’t know if it’s the case here, but it’s something to remember.

You need the pointer address for the imagewrapper.

IImageWrapperModule& ImageWrapperModule = FModuleManager::LoadModuleChecked(FName(ImageWrapper));

Then you need an fstring for it, for the file name and the type image you are loading. You are using an object oriented class and may have these elsewhere.

There is also other things once you load the image wrapper to the array.

It was part of a tutorial for super basic explanations. Literally using the log function not to log anything but just for the sake of checking it out in the output window.
I think my messing around with stuff inside my vs studio was causing an issue. Heck, I wasn’t even trying to use the image wrapper module let alone heard of it. Thanks for the replies!