Leadtools.Dicom Requires Medical product license | Send comments on this topic. | Back to Introduction - All Topics | Help Version 16.5.9.25
UpdateOverlayBox Method
See Also 
Leadtools.Dicom Namespace > DicomPrintScu Class : UpdateOverlayBox Method



overlayBoxInstanceUid
The SOP Instance UID of the Image Overlay Box to be updated. The method will fail if this is a null reference (Nothing in Visual Basic) or if an empty string is specified.
overlay
A DicomDataSet object that contains the Overlay data for the specified Image Overlay Box. The object is assumed to contain the Overlay Pixel Data Sequence (2040,0020); the method will fail if this Sequence is not present. This parameter can be set to a null reference (Nothing in Visual Basic) if the Overlay data is not to be updated.
parameters
A DicomOverlayBoxParameters object that specifies the Image Overlay Box parameters to be updated. This can be set to a null reference (Nothing in Visual Basic) if none of the parameters is to be updated.
updateOverlayOrigin
true to update the Overlay Origin (6000,0050) as determined by the properties DicomOverlayBoxParameters.OverlayOriginRow and DicomOverlayBoxParameters.OverlayOriginColumn in the object specified by parameters (these properties can be negative); otherwise, false. In the latter case, the Attribute will not be included in the request to the Print SCP. If parameters is set to a null reference (Nothing in Visual Basic), updateOverlayOrigin will be ignored.
overlayBoxInstanceUid
The SOP Instance UID of the Image Overlay Box to be updated. The method will fail if this is a null reference (Nothing in Visual Basic) or if an empty string is specified.
overlay
A DicomDataSet object that contains the Overlay data for the specified Image Overlay Box. The object is assumed to contain the Overlay Pixel Data Sequence (2040,0020); the method will fail if this Sequence is not present. This parameter can be set to a null reference (Nothing in Visual Basic) if the Overlay data is not to be updated.
parameters
A DicomOverlayBoxParameters object that specifies the Image Overlay Box parameters to be updated. This can be set to a null reference (Nothing in Visual Basic) if none of the parameters is to be updated.
updateOverlayOrigin
true to update the Overlay Origin (6000,0050) as determined by the properties DicomOverlayBoxParameters.OverlayOriginRow and DicomOverlayBoxParameters.OverlayOriginColumn in the object specified by parameters (these properties can be negative); otherwise, false. In the latter case, the Attribute will not be included in the request to the Print SCP. If parameters is set to a null reference (Nothing in Visual Basic), updateOverlayOrigin will be ignored.
Requests the Print SCP to update the specified Basic Print Image Overlay Box SOP Instance.

Syntax

Visual Basic (Declaration) 
Public Sub UpdateOverlayBox( _
   ByVal overlayBoxInstanceUid As String, _
   ByVal overlay As DicomDataSet, _
   ByVal parameters As DicomOverlayBoxParameters, _
   ByVal updateOverlayOrigin As Boolean _
) 
Visual Basic (Usage)Copy Code
Dim instance As DicomPrintScu
Dim overlayBoxInstanceUid As String
Dim overlay As DicomDataSet
Dim parameters As DicomOverlayBoxParameters
Dim updateOverlayOrigin As Boolean
 
instance.UpdateOverlayBox(overlayBoxInstanceUid, overlay, parameters, updateOverlayOrigin)
C# 
public void UpdateOverlayBox( 
   string overlayBoxInstanceUid,
   DicomDataSet overlay,
   DicomOverlayBoxParameters parameters,
   bool updateOverlayOrigin
)
C++/CLI 
public:
void UpdateOverlayBox( 
   String^ overlayBoxInstanceUid,
   DicomDataSet^ overlay,
   DicomOverlayBoxParameters^ parameters,
   bool updateOverlayOrigin
) 

Parameters

overlayBoxInstanceUid
The SOP Instance UID of the Image Overlay Box to be updated. The method will fail if this is a null reference (Nothing in Visual Basic) or if an empty string is specified.
overlay
A DicomDataSet object that contains the Overlay data for the specified Image Overlay Box. The object is assumed to contain the Overlay Pixel Data Sequence (2040,0020); the method will fail if this Sequence is not present. This parameter can be set to a null reference (Nothing in Visual Basic) if the Overlay data is not to be updated.
parameters
A DicomOverlayBoxParameters object that specifies the Image Overlay Box parameters to be updated. This can be set to a null reference (Nothing in Visual Basic) if none of the parameters is to be updated.
updateOverlayOrigin
true to update the Overlay Origin (6000,0050) as determined by the properties DicomOverlayBoxParameters.OverlayOriginRow and DicomOverlayBoxParameters.OverlayOriginColumn in the object specified by parameters (these properties can be negative); otherwise, false. In the latter case, the Attribute will not be included in the request to the Print SCP. If parameters is set to a null reference (Nothing in Visual Basic), updateOverlayOrigin will be ignored.

Example

Remarks

Two of the exceptions that can be thrown by this method are:
Exception TypeCondition
DicomExceptionCode.PrintSCUFailureStatus The response of the Print SCP specifies a Failure status code.
DicomExceptionCode.PrintSCUClassNotSupported The Basic Print Image Overlay Box SOP Class is not supported on the Association.

The method will fail if both overlay and parameters are set to null references (Nothing in Visual Basic).

The Image Overlay Box specified (by the SOP Instance UID) must be an exiting one. Refer to the method CreateOverlayBox for creating Image Overlay Boxes.

The method will not return until it receives the response of the Print SCP, or an error occurs. The method GetLastOperationStatus can be used to obtain the status code specified in the response of the Print SCP. If the method UpdateOverlayBox is successful, the specified Image Overlay Box was updated successfully, with either a Success or Warning status code in the response of the Print SCP.

In the DicomOverlayBoxParameters object specified by the parameter parameters, if a string property is a null reference (Nothing in Visual Basic), then the corresponding Attribute will not be included in the request to the Print SCP and hence will not be updated. Also, if the property DicomOverlayBoxParameters.MagnifyToNumberOfColumns is negative, the corresponding Attribute will not be included in the request and hence will not be updated.

Requirements

Target Platforms: Microsoft .NET Framework 3.0, Windows XP, Windows Server 2003 family, Windows Server 2008 family

See Also

Leadtools.Dicom requires a Medical toolkit server license and unlock key. For more information, refer to: Imaging Pro/Document/Medical Features