Hay there guys
I have a little trouble in my music player, see I had all the necessary code to make the player shuffle, loop etc.
But my player form looked very messy with all that tons of code, so I decided to condense all that code in a class called "Player", to me just to instantiate.
Now here is the dilema, since I have a axWMP1 object with a GUI interface in my form I wouldnt like to instantiate a new in my Player class so I made a constructor that requests a [AxWMPLib.AxWindowsMediaPlayer] object and just use it with all the complex and large methods I wrote.
AxWMPLib.AxWindowsMediaPlayer player;
public Player(AxWMPLib.AxWindowsMediaPlayer mediaPlayer)
{
this.player = mediaPlayer;
}
I have that code but it has a syntax error I dont know how to correct.
it happens when I instantiate the object:
Player mediaPlayer = new Player(axWMP1);
What´s the correct whay of doing this?
NOTE: I cant create a new object inside my class because the object in the form contains the GUI interface I need to display videos as well.
Thanks!