Skip to content

Wrong implementation of GetObjectData for VB #25753

@oahrens

Description

@oahrens

Instead of

Private Sub GetObjectData(ByVal info As SerializationInfo, ByVal context As StreamingContext)
    Implements ISerializable.GetObjectData
    If info Is Nothing Then
        Throw New System.ArgumentNullException("info")
        info.AddValue("name", FullName)
    End If
End Sub

the implementation should be

Private Sub GetObjectData(ByVal info As SerializationInfo, ByVal context As StreamingContext)
    Implements ISerializable.GetObjectData
    If info Is Nothing Then
        Throw New System.ArgumentNullException("info")
    End If
    info.AddValue("name", FullName)
End Sub

Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions