Optimizing WPF Application Startup Time on Shared Network Drive

Knot 0 Reputation points
2025-01-07T03:15:44.66+00:00

My team is facing an issue when publishing the application on a shared network drive. When an end user opens the program for the first time after starting their computer, it takes significantly longer compared to running it from the local C drive (18 seconds on the shared network drive vs. 3 seconds on the C drive). Are there any tools or techniques to reduce the file size or optimize the WPF program to make it open faster?

.NET
.NET
Microsoft Technologies based on the .NET software framework.
4,035 questions
Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,807 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Hongrui Yu-MSFT 3,730 Reputation points Microsoft Vendor
    2025-01-07T07:06:08.5466667+00:00

    Hi, @Knot. Welcome to Microsoft Q&A. 

    You could refer to the following optimization solutions:

    1. The IO and network reading speeds are too slow, and the initialization program needs to load too many modules (.dll files). Could these modules be loaded dynamically after the program starts? Or preload commonly used dependent libraries and resource files when the program starts, and cache them locally to reduce the dependence on the network during operation.
    2. Could the initialization logic (for example: data loading) be executed after the program starts, or asynchronously executed.
    3. Segmented loading: Divide large resource files into multiple small files and load them on demand to avoid transmitting large amounts of data at one time.
    4. Could a startup screen be added to optimize the user experience

     

    More optimization solutions: Application Startup Time - WPF .NET Framework | Microsoft Learn


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


  2. Bruce (SqlWork.com) 69,121 Reputation points
    2025-01-07T16:45:10.5266667+00:00

    if you are using click once deployment, then the application must be copied to the local computer to run when first run.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.