vs2012sliverlight 播放音频文件

我用vs2012sliverlight 播放wma文件,按照silverlight从入门到精通 关于媒体播放mediaelement的使用,步骤一样,可是浏览器无法播放,运行时没有提示出错???
声音文件已经添加到工程目录,MediaElement设置为“永远图片说明复制”,“RESOURCE”
图片说明

``` xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="400">

<Grid x:Name="LayoutRoot" Background="White">

    <StackPanel Orientation="Vertical">
        <MediaElement  x:Name="mediaplay" HorizontalAlignment="Left" 
                       Height="100" VerticalAlignment="Top" Width="100" Source="ALARM.WAV"/>
        <StackPanel Orientation="Horizontal">
            <Button x:Name="play" Content="播放" Height="100" Width="100" Click="play_Click"/>
        </StackPanel>
    </StackPanel>
</Grid>

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace AlarmVoice
{
public partial class MainPage : UserControl
{
public MainPage()
{
InitializeComponent();
}

    private void play_Click(object sender, RoutedEventArgs e)
    {
        mediaplay.Play();
    }
}

}




建议你先试试 Media Player 能不能播放这个 WMA 文件。

你是听不见声音吧?

你设置了Volumn大小了嘛?你设置为1试试

兄弟 你这个问题解决了么 我也遇到这个问题