Binoy Dalal
Binoy Dalal

Reputation: 896

Windows API to change audio tracks

what is/are the windows API function that is called when i hit the next/previous and the play track button in windows media player/itunes? if you are not aware of the exact API function, is there some quick way (by using some software) to find what function is called when you hit the button?

thanks

binoy

Upvotes: 3

Views: 287

Answers (2)

Hexar
Hexar

Reputation: 583

I'm not sure about Windows Media Player, but there is an iTunes COM interface for programmatically interacting with iTunes on Windows. There is a short tutorial on using the COM API with C# here: http://www.ohscope.com/2009/04/02/itunes-com-api-in-c/

I'm also not sure if you're asking about making iTunes play a track (which you can do) or if you just want to get a callback when a track starts playing (which you can also do).

Upvotes: 2

Ben Voigt
Ben Voigt

Reputation: 283893

If you mean next and previous CD track, you are probably looking for the Media Control Interface (MCI).

If you mean from a playlist, then there is no such API. Media players manage the playlist themselves, and changing song consists of stopping the old and starting the new. There's no next/previous for playlists provided by Win32.

Upvotes: 0

Related Questions