dotnet/wpf · warning · NotImplementedException

NotImplementedException

Error message

NotImplementedException

What it means

NativeProgressPageProxy.DeploymentPath is a write-only COM-facing proxy property: the setter is intentionally empty and the getter throws NotImplementedException. The native progress page never reads the path back through this managed proxy, so reading it is unsupported by design.

Solutions

  1. Do not read DeploymentPath; keep the value on the managed/native side that sets it.
  2. Store the deployment URI in your own field when you set it, and read from that instead.
  3. Skip read of getter-only-unsupported properties when reflecting over the proxy (guard with try-catch NotImplementedException).

Example fix

// before
var path = progressPage.DeploymentPath;
// after
Uri path = myDeploymentPathHolder ?? null; // captured when the setter was called
Defensive patterns

Strategy: type-guard

Validate before calling

bool canReadDeploymentPath = progressPage is not NativeProgressPageProxy;
if (canReadDeploymentPath) { var p = progressPage.DeploymentPath; }

Type guard

static bool HasReadableDeploymentPath(object page) =>
    page is NativeProgressPageProxy ? false : page?.GetType().GetProperty("DeploymentPath")?.CanRead == true;

Try / catch

Uri path;
try { path = progressPage.DeploymentPath; }
catch (NotImplementedException) { path = myStoredDeploymentPath; }

Prevention

When it happens

Trigger: Reading the DeploymentPath property of a NativeProgressPageProxy instance obtained via the WPF ClickOnce progress-page hosting path.

Common situations: Reflection-based or debugging code enumerating properties of the progress page proxy and reading every getter; custom progress UI code that mistakenly assumes the property is readable.

Related errors


AI-assisted analysis of dotnet/wpf@81131a70a4 (2026-09-14). Data as JSON: /api/errors/b5a60220aa1c4720. Report an issue: GitHub.

Appendix: source

Thrown at src/Microsoft.DotNet.Wpf/src/PresentationFramework/MS/Internal/AppModel/ProgressPage.cs:62

    };

    internal class NativeProgressPageProxy : IProgressPage2
    {
        internal NativeProgressPageProxy(INativeProgressPage npp)
        {
            _npp = npp;
        }

        public void ShowProgressMessage(string message)
        {
            // Ignore the error code.  This page is transient and it's not the end of the world if this doesn't show up.
            HR hr = _npp.ShowProgressMessage(message);
        }

        public Uri DeploymentPath
        {
            set { }
            get { throw new System.NotImplementedException(); }
        }

        /// <remarks>
        /// The native progress page sends a stop/cancel request to its host object, which then calls 
        /// IBrowserHostServices.ExecCommand(OLECMDID_STOP).
        /// </remarks>
        public DispatcherOperationCallback StopCallback
        {
            set { }
            get { throw new System.NotImplementedException(); }
        }

        /// <remarks>
        /// The native progress page sends a Refresh request to its host object, which then calls 
        /// IBrowserHostServices.ExecCommand(OLECMDID_REFRESH).
        /// </remarks>
        public System.Windows.Threading.DispatcherOperationCallback RefreshCallback
        {

View on GitHub (pinned to 81131a70a4)