C#WPF很慢启动第一次很慢、WPF

由网友(曾经沧海)分享简介:我谏只创建一个按钮,一个简单的WPF应用程序来检查性能问题.. 这是痛苦的缓慢,以体面的机器才开始第一次活动。我建立一个可执行的发布模式优化,但第一次是约15秒的磁盘IO是在这段时间..它运行的第二个时间更快不到1秒的高... 我认为,这是太多的时间...... I was adviced to just cr...

我谏只创建一个按钮,一个简单的WPF应用程序来检查性能问题.. 这是痛苦的缓慢,以体面的机器才开始第一次活动。 我建立一个可执行的发布模式优化,但第一次是约15秒的磁盘IO是在这段时间..它运行的第二个时间更快不到1秒的高... 我认为,这是太多的时间......

I was adviced to just create a simple wpf application with a button to check the performance problems.. It is painfully slow to start only first time event in decent machines. I have built an executable in release mode optimised but first time is about 15 seconds disk IO is high during that time.. The second time it runs is faster less than 1 sec... I believe that it is too much time...

我添加的文件app1.config

I added a file app1.config

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <runtime>
    <generatePublisherEvidence enabled="false"/>
  </runtime>
</configuration>

APP1心不是应用程序的名称..但没有帮助...

app1 isnt the name of the app.. but didnt help...

任何想法,该怎么办?

推荐答案

在某些机器上,如果你从来没有因为启动应用程序的启动可能是痛苦的运行WPF应用程序。在你的启动文件夹 - 您可以通过运行任何WPF应用程序(只引用一个无需显示窗口),添加一个快速入门。这将确保在dot-NET Framework在满载和你的应用程序应该载入速度更快,虽然这会慢启动了一下。

On some machines if you've never run a WPF app since bootup the application startup can be painful. You could add a "quickstart" by running any WPF app (without needing to display a window -- just reference one) in your startup folder. That will ensure the dot-net framework is fully loaded and your app should load faster, though this will slow bootup a bit.

阅读全文

相关推荐

最新文章