I want to make a voice recorder app but it crashes when i click the \"Start Recording\" button. I get an error saying java.lang.IllegalStateException at android.media.Media
you are forgetting to call recorder.prepare() before recordeer.start() function in your beginRecording function.
recorder.prepare()
recordeer.start()
beginRecording
Prepare function will take care about lot of things like conversion of analog data to digital audio for compresion and where to store the file etc