NotImplementedException Class (System) (original) (raw)

Definition

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

The exception that is thrown when a requested method or operation is not implemented.

public ref class NotImplementedException : Exception
public ref class NotImplementedException : SystemException
public class NotImplementedException : Exception
public class NotImplementedException : SystemException
[System.Serializable]
public class NotImplementedException : SystemException
[System.Serializable]
[System.Runtime.InteropServices.ComVisible(true)]
public class NotImplementedException : SystemException
type NotImplementedException = class
    inherit Exception
type NotImplementedException = class
    inherit SystemException
[<System.Serializable>]
type NotImplementedException = class
    inherit SystemException
[<System.Serializable>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type NotImplementedException = class
    inherit SystemException
Public Class NotImplementedException
Inherits Exception
Public Class NotImplementedException
Inherits SystemException

Inheritance

Inheritance

Attributes

Examples

The following example throws this exception for a method that has not been developed.

static void Main(string[] args)
{
    try
    {
        FutureFeature();
    }
    catch (NotImplementedException notImp)
    {
        Console.WriteLine(notImp.Message);
    }
}

static void FutureFeature()
{
    // Not developed yet.
    throw new NotImplementedException();
}
open System

let futureFeature () =
    // Not developed yet.
    raise (NotImplementedException())

[<EntryPoint>]
let main _ =
    try
        futureFeature ()
    with :? NotImplementedException as notImp ->
        printfn $"{notImp.Message}"
    0
Sub Main()
    Try
        FutureFeature()
    Catch NotImp As NotImplementedException
        Console.WriteLine(NotImp.Message)
    End Try


End Sub

Sub FutureFeature()
    ' not developed yet.
    Throw New NotImplementedException()
End Sub

Remarks

For more information about this API, see Supplemental API remarks for NotImplementedException.

Applies to

See also