Well, I made a game, and I have two MMControls on it, one to play background music, and one to play sound effects. Since so many parts of the program need to access these controls, I decided the entire music control into one public sub on a module, as shown here:

VB Code:
  1. Public Sub SoundEffect(strSound As String, mmController As MMControl)
  2.  
  3.     frmGameScreen.mmController.Command = "close"
  4.     frmGameScreen.mmController.Command = "Stop"
  5.  
  6.     frmGameScreen.mmController.FileName = App.Path & "\sounds\" + Trim(strSound)
  7.  
  8.     frmGameScreen.mmController.Command = "open"
  9.     frmGameScreen.mmController.Command = "play"
  10.        
  11. End Sub

The problem is when I try to call the procedure with a line like this:
VB Code:
  1. Call SoundEffect("EXPLODE.WAV", mmMusicControl)

I get an error saying "Method or data member not found", is it not possible to do what I want to do without copying the code for both control twice? I want to avoid as much extra code as possible. Can somebody help me?