You can't write to stdin: it is a read-only stream. It would be the equivalent of writing to your mouse and expecting the user to read the message...
You could use fprintf to write to stdout:
fprintf(stdout, "Enter the data\n");
fgets(buffer,250,stdin);
But printf is the equivalent of that anyway - many implementations do exactly that: call fprintf from printf with stdout as the stream parameter.