Title:To help protect your security, your web browser has restricted this file from showing active content that could access your computer. Click here for options...
在WPF窗口中,使用WebBrowser控件打开flash,可能会弹出以下的警告信息,而导致你无法在第一时间看到flash,必须右键单击警告框,选择“允许被组织的内容”,才能正常看到flash:
To help protect your security, your web browser has restricted this file from showing active content that could access your computer. Click here for options...
为了帮助保护您的安全,您的浏览器已经限制此文件显示可能访问您的计算机的活动内容。单击此处查看选项……
如下图:
解决办法:
在指定WebBrowser的source的时候,使用文件系统路径,例如:
<Window x:Class="B1Motion.ViewDashboard"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="ViewDashboard" Height="1010" Width="1900">
<Grid>
<WebBrowser x:Name="WebBrowser1" Source="file://127.0.0.1/c$/dashboard1.swf"></WebBrowser>
</Grid>
</Window>
这样,就可以避免弹出警告信息了。