You'll need to go into some detail to explain "not working".
What happened before it stopped working? was it shutdown? did you get an error message? etc.
There should be no problem changing out the HDD for a new one, but that brings it's own complications (reinstalling windows for example).
if you can explain the circumstances, you might even be able to get your HDD up and running again without replacing.