error C2447: '{' : missing function header (old-style formal l

error C2447: '{' : missing function header (old-style formal l

Page 1 of 1

1 Replies - 7323 Views - Last Post: 24 August 2010 - 05:11 AM Rate Topic: -----

#1 tnecniv  Icon User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 109
  • Joined: 03-October 09

error C2447: '{' : missing function header (old-style formal l

Posted 24 August 2010 - 05:06 AM

Its being awhile i have done programing.. can someone please help me see what is wrong with my code?

#include "database.h"

void addL();

int main()
{
	cout<<"Welcome to SimpleRoutestore!"<<endl;
	addL();
	
	return 0;
}

void addL();
{	
	string option;
	string locationName;

	cout<<"entercommand:"<<endl;
	cin>>option>>locationName;

	if(option=="addlocation"){
	addlocation(locationName);
	}
	

}

error C2447: '{' : missing function header (old-style formal list?)

Is This A Good Question/Topic? 0
  • +

Replies To: error C2447: '{' : missing function header (old-style formal l

#2 Crunch  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 139
  • View blog
  • Posts: 1,222
  • Joined: 28-July 09

Re: error C2447: '{' : missing function header (old-style formal l

Posted 24 August 2010 - 05:11 AM

I think i spotted the error

void addL();{


what is a ; doing after the () brackets ?
Was This Post Helpful? 2
  • +
  • -

Page 1 of 1