Media Player and Streaming Player in the same service?

GuyBooth

Active Member
Licensed User
Longtime User
I'm trying to have both a MediaPlayer and a MediaPlayerStreamer in the same service. I initialize both in the service, and call on one or the other to play music files.
B4X:
    MPP.Initialize2("MPP")
    MPS.Initialize("MPS")
This seems to work most of the time, but when I invoke this to determine which one is in use, I get an "IllegalStateException" error, particularly it seems when the Streamer is in use:
B4X:
If (MPP.IsPlaying OR MPS.IsPlaying) Then

Am I trying to do something that is not allowed?
 
Top