I am trying to use a function to save a word to a global string, depending on what the user input was.
the code goes like this:

Code:
char g_string[255]; //declare global sting
int main(void)
{
//main program
}

int changestring(int y)
{
   switch (y)
   {
    case 1:
          {
            strcpy (g_string, "word to be used");
            break;
          }
    case 2:
          {
           strcpy (g_string, "other word");
           break;
          }
   }
return 0;
}
When I compile, I get the message 'strcpy' is 'unidentified'
what am I doing wrong?
please help.
thanx.