What you're trying to do definitely works. I tried it by implementing the MCI in the simplest form that I could and now have music playing from a blank console window.
Put this into a new class called 'File' and remember to reference the System.Runtime.InteropServices namespace:
static extern int mciSendString(string mciCommand, StringBuilder buffer, int bufferSize, IntPtr callback);
public void Send(string mciCommand)
mciSendString(mciCommand, null, 0, IntPtr.Zero);
public File(string fileLocation)
fileName = fileLocation;
Send("open " + fileName);
public void Play()
Send("play " + fileName);
Then drop this into your startup object:
File file = new File("C:/Test.mp3");
string input = Console.ReadLine();
It should work now. At the moment it won't do anything other than play the file but the MSDN section on MCI
describes all the additional commands that can be called.