DicomObjects.NET.8.48 Documentation
DicomObjects Namespace / DicomDataSet Class / Remove Method / Remove(Int32,Int32) Method

The group index of a data element

The element index of a data element

Example

In This Topic
    Remove(Int32,Int32) Method
    In This Topic
    Removes an attribute from the DataSet
    Syntax
    'Declaration
     
    
    Public Overloads Sub Remove( _
       ByVal Group As System.Integer, _
       ByVal Element As System.Integer _
    ) 
    public void Remove( 
       System.int Group,
       System.int Element
    )

    Parameters

    Group

    The group index of a data element

    Element

    The element index of a data element

    Remarks

    If the appropriate data element exists in the DicomDataSet, it is removed.

    No error is generated if the requested item is not present in the DataSet.

    Example
    DicomDataSet ds = new DicomDataSet("Dataset.dcm");
    int group = 0x0010;
    int element = 0x0010;
                        
    ds.Remove(group, element); // remove patient name
    var pn = ds[Keyword.PatientName].Value.ToString(); // null
    Requirements

    Target Platforms: .NET CLR 4.8 or higher

    See Also