I'm trying to record audio data from a microphone (or line-in), and then replay it again, using C#.
Any suggestions on how I can achieve this?
have a look at the open source .NET Voice Recorder project which uses NAudio. There is an article on Coding4Fun explaining how it works.