开发者

Silverlight: Set windowless to true but not in HTML/ASPX

I am trying开发者_如何学编程 to find out how to set the windowless parameter to true, but not in the object tag, but directly in the Silverlight Application. I don't know if that possible, but i thought maybe this can be done in the app.xaml?

any ideas?

Christian


That parameter can not be set after the Silverlight Application has loaded. You can check the parameter with Application.Current.Host.Settings.Windowless, but it is a read-only property.

If you need to programmatically decide whether to set windowless mode, you will have to do it in the page that hosts the Silverlight XAP. Your best bet is probably to use a StringBuilder to generate the entire <object> tag in the code-behind of your ASPX page (or even wrap the entire object tag up as a CompositeControl) and pass an isWindowless bool in as a parameter.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜