I am an absolute newbie to C++ and Unreal.
TArray<FStarNames*> GetList; StarNamesTable->GetAllRows<FStarNames>(TEXT("Starname retrieval failed"), GetList); int NameCount = GetList.Num(); UE_LOG(LogTemp, Warning, TEXT("Star Names Imported %d"), NameCount); auto MyName = GetList; UE_LOG(LogTemp, Warning, TEXT("First Star Name Imported %s"), MyName);
FStarNames is coming out of a data table where the only item in the FStarNames struct is an FString. The data table shows up correctly when viewed in the UE4 editor.
The data table is being imported and NameCount results in the correct number of items in the data table.
The problem is: as coded ‘MyName’ generates garbage characters when passed to the UE_LOG. Dereferencing ‘MyName’ in the UE_LOG line throws compiler errors: “non-portable use of class ‘FStarNames’ as an argument to a variadic function”
Directly setting MyName to FString instead of ‘auto’ gets this compiler error: “cannot convert from ‘FStarNames *’ to ‘FString’”.
So what am I missing here?