few problems if your just passing back a pointer to the string then
you should probly be either defining the char array in main function otherwise when the function is closed the memory is freed and you could loose your information, the following will work, not 100% what you need:
Code:
// What does number do??
char* Array_string(char *inputstring,char *chararray)
{
strcpy(chararray,inputstring);
return chararray
}
int main( )
{
char str[256];
char *string;
string=Array_string("testing",str);
printf("OUT STRING: %s",string);
return 0;
}
hope this helps you understand, basically before when you do:
char *str[256];
it actually creates 256 pointers in an array no character memory is defined.