I am getting the error unresolved External symbol _applicationStartup referenced in function main. I have the function declared and defined correctly but it keeps giving the error. These are the main parts of the code, everything is stored and saved in the same file.
#include <stdio.h>
#include "accountTicketingUI.h"
#define ACCOUNT_SIZE 50
#define TICKET_SIZE 50
void populateAccounts(struct Account accounts[], int arrSize);
void populateTickets(struct Ticket tickets[], int arrSize);
int main(void)
{
struct Account accounts[ACCOUNT_SIZE] = { {0} };
struct Ticket tickets[TICKET_SIZE] = { {0} };
struct AccountTicketingData data = { accounts, ACCOUNT_SIZE, tickets, TICKET_SIZE };
populateAccounts(data.accounts, data.ACCOUNT_MAX_SIZE);
populateTickets(data.tickets, data.TICKET_MAX_SIZE);
applicationStartup(&data);
return 0;
}
In accountTicketingUI.h I declare application startup first.
#include <stdio.h>
#include "account.h"
#include "ticket.h"
void applicationStartup(struct AccountTicketingData*);//starting function to call everything
void pauseExecution(void);//pause function
int displayAccountDetailHeader();//displays the header
int displayAccountDeatailRecord(struct Account *);//function to display records
int menuLogin(const struct Account accounts[], int max);//login function
int menuAgent(struct AccountTicketingData*, const int ptr);//menu for the user
int displayAllAccountDetailRecords(const struct Account accounts[], int max);//displas everything an encrypts it
int findAccountIndexByAcctNum(int num, const struct Account accounts[], int max, int prompt);
struct AccountTicketingData
{
struct Account* accounts;
const int ACCOUNT_MAX_SIZE;
struct Ticket* tickets;
const int TICKET_MAX_SIZE;
};
And here is the actual code for application startup
void applicationStartup(struct AccountTicketingData *accounts[])
{
int index;//loops and index holders
while (1)
{
index = menuLogin(accounts, ACCOUNT_MAX_SIZE);
if (index != -1)
{
menuAgent(accounts, ACCOUNT_MAX_SIZE, index);
}
else {
break;
}
}
printf("==============================================\n");
printf("Account Ticketing System - Terminated\n");
printf("==============================================\n\n");
}