TActorIterator incomplete class type

Did you include the APlayerStart header file?

Hey guys,
I am very new to UE4, an I am stumbling upon the following:
I am using the exact same code as mentioned , only looking for APlayerStart instead of AStaticMeshActor. (I am talking about the very bottom code snippet). Unfortunately, Visual Studio won’t compile this, outputting the Error:

error C2027: use of undefined type ‘APlayerStart’

When I try to use TObjectIterator or TActorIterator, it doesn’t work either.
What should I do?

EDIT:
When I hover over the iterator in the next line (which is of course underlined red) it tells me

Error: Pointer to incomplete class type is not allowed
Is that because of a missing include? I did, however, include EngineUtils.h, so it’s not that…

there is just PlayerStart.generated.h, right?

No the file you are looking for is “PlayerStart.h”
You can get directly to it from the editor if you need to read it.

17526-playerstart.h.jpg

// Copyright 1998-2014 Epic Games, Inc. All Rights Reserved.

//=============================================================================
// Player start location.
//=============================================================================

#pragma once
#include "PlayerStart.generated.h"

UCLASS(ClassGroup=Common, hidecategories=Collision)
class ENGINE_API APlayerStart : public ANavigationObjectBase
{
	GENERATED_UCLASS_BODY()

	/** Used when searching for which playerstart to use. */
	UPROPERTY(EditAnywhere, BlueprintReadWrite, Category=Object)
	FName PlayerStartTag;

#if WITH_EDITORONLY_DATA
	UPROPERTY()
	TSubobjectPtr<class UArrowComponent> ArrowComponent;
#endif

	virtual void PostInitializeComponents() override;
	
	virtual void PostUnregisterAllComponents() override;
};

is there an easy way to find out, where that header file is located?
I found that specific one, but it would help if I knew a way to find the location without looking into the documentation.

Visual Studio RMB → Go to Declaration / Go to Definition would find it. Also CTRL-, will allow quick search for a symbol or file.

In general all classes are in a file named after their class without the prefix “A” or “U” or whatever.

Theres ready array of player starts in AGameMode

https://docs.unrealengine.com/latest/INT/API/Runtime/Engine/GameFramework/AGameMode/PlayerStarts/index.html

thank you