如何动态更改silverlight应用程序的OOB高度/宽度?

时间:2010-03-29 09:06:21

标签: silverlight out-of-browser

我有一个 silverlight 应用,可以由用户安装为浏览器外应用。

每当我更改应用程序的高度宽度时,我还必须:

  • 右键单击项目
  • 属性
  • 点击浏览器外设置按钮
  • 手动更改高度和宽度

如何在代码中更改浏览器外应用程序的定义高度和宽度?

1 个答案:

答案 0 :(得分:1)

我用这个:

private void Application_Startup(object sender,StartupEventArgs e) { MyBlueForm = new MyBlueForm();

this.RootVisual = startupWindow;

this.MainWindow.Width = startupWindow.Width; this.MainWindow.Height = startupWindow.Height; }