Error: variable or field 'UpdateTopInfo' declared void

I know this question has been posted a few times before, but the answers in those threads didn’t seem to help me.

vTopInfoGUITask is called from the main function (in another Tab), the header file is brought in via #include in the Main Tab (that should work, correct?).


Task_GUI_TopInfo_Main:23: error: variable or field 'UpdateTopInfo' declared void
 void UpdateTopInfo(GUI_TopInfoBarClass *TopInfoBar)


Task_GUI_TopInfo_Main:23: error: 'GUI_TopInfoBarClass' was not declared in this scope
Task_GUI_TopInfo_Main:23: error: 'TopInfoBar' was not declared in this scope
 void UpdateTopInfo(GUI_TopInfoBarClass *TopInfoBar)


//GUI Elements for top info bar

//Main FreeRTOS task
//Rests for 1 second between updates
static void vTopInfoGUITask(void *pvParameters)
	GUI_TopInfoBarClass TopInfoBar;


		// Sleep for 1000 milliseconds.
		vTaskDelay((1000L * configTICK_RATE_HZ) / 1000L);


#define SerialPrintTrigger 5 //Counter increases every second so trigger's in seconds

//Redraws top info bar with latest status elements
void UpdateTopInfo(GUI_TopInfoBarClass *TopInfoBar)         <------ERROR THROWN HERE

	static unsigned long SerialPrintCounter = 0;

	//Iridium stats
	int signalQuality = _GlobalSignalQuality;
	int messagesWaiting = _GlobalMessageWaiting;

	//Colour controls top info bar based on signal strength availible from Iridium

	//Update Text String for Top Info Box
	TopInfoBar->UpdateText(signalQuality,messagesWaiting, _GlobalMyCommStatus, CodeVersion,_GlobalQuedMessage, _GlobalMessageFileQueIndex);

	//Write latest box details to screen

	//Serial printout of status
	if(SerialPrintCounter >= SerialPrintTrigger)
		Serial.println("Status: " + TopInfoBar->getContents());
		SerialPrintCounter = 0;


	//Sensor internal temp read. Added here until secondary task for sensor reading is created
	_GlobalInternalTemp = InternalTempRead();

Header File:

// GUI_TopInfoBar.h


#if defined(ARDUINO) && ARDUINO >= 100
	#include "arduino.h"
	#include "WProgram.h"

#ifndef ILI9341_BLACK
#include <ILI9341_t3.h>

#ifndef _TFT_TEXTBOX_h
#include "TFT Libraries/TFT_TextBox.h"

#include "Iridium Classes/Iridium_Handler.h"

class GUI_TopInfoBarClass
 ILI9341_t3 *_tft;
 TFT_TextBoxClass _TopInfoBar;
 uint16_t _BoxColour = 0;
 String _TopMessage = "";
	void init();

	void setup(ILI9341_t3 tft);//Main setup of class. Passes ILI9341 element

	void UpdateStatusColour(int Status); //Set colour of box based on signal status

	void UpdateText(int signalQuality, int MessagesWaiting, int IridiumStatus, String CodeVersion,int MessageQueLength, int MessageQuePosition ); //Update Text based on status info

	void UpdateScreen();//Write latest contents to screen

	String getContents() {return _TopMessage;};//Return String contents


extern GUI_TopInfoBarClass GUI_TopInfoBar;



Your 'code' doesn't include the 'include' file.

The declaration of the function parameter fails because 'GUI_TopInfoBarClass' is not declared.

In general, if you can't figure out the first error message, look at subsequent error messages until you can find one you can fix, then try again. With luck, the first message is caused by a mistake further down.