Imports System.IO Imports System.Media Public Class Form1 Private wavData As Byte() Private player As SoundPlayer Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load wavData = File.ReadAllBytes(ファイル名) player = New SoundPlayer() End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click player.Stream = New MemoryStream(wavData) player.Play() End Sub End Class