# UnknownUnionCaseException

Package: [Microsoft.Orleans.Serialization](/orleans/docs/api/csharp/microsoft.orleans.serialization/) 10.0.0

[NuGet package](https://www.nuget.org/packages/Microsoft.Orleans.Serialization) | [Source](https://github.com/dotnet/orleans/blob/4e887e9c914a2f2647fb3c81de963511521dd9cb/src/Orleans.Serialization/Exceptions.cs#L173)

```csharp
[Orleans.GenerateSerializer]
public sealed class UnknownUnionCaseException : SerializerException
```

A serialized tagged-union value identifies a case which the union type or closed type hierarchy does not declare.

## Remarks

This occurs when data written by a newer version of a type, which declares additional cases, is read by an older version of that type.

## Constructors

- [UnknownUnionCaseException(Type, uint)](/orleans/docs/api/csharp/microsoft.orleans.serialization/orleans.serialization.unknownunioncaseexception/constructors/constructor-system-type-uint-1ece8175/)
