ClearCanvas.Dicom.Network.NetworkBase.SendCStoreResponse C# (CSharp) Method

SendCStoreResponse() public method

Method to send a DICOM C-STORE-RSP message.
public SendCStoreResponse ( byte presentationID, ushort messageID, string affectedInstance, ClearCanvas.Dicom.Network.DicomStatus status, string errorComment ) : void
presentationID byte
messageID ushort
affectedInstance string
status ClearCanvas.Dicom.Network.DicomStatus
errorComment string An extended textual error comment on failure. The comment will be truncated to 64 characters.
return void
        public void SendCStoreResponse(byte presentationID, ushort messageID, string affectedInstance, DicomStatus status, string errorComment)
        {
            var msg = new DicomMessage
            {
                MessageIdBeingRespondedTo = messageID,
                CommandField = DicomCommandField.CStoreResponse,
                AffectedSopClassUid = _assoc.GetAbstractSyntax(presentationID).UID,
                AffectedSopInstanceUid = affectedInstance,
                DataSetType = 0x0101,
                Status = status,
            };

            if (!string.IsNullOrEmpty(errorComment))
            {
                msg.ErrorComment = errorComment.Substring(0, (int)Math.Min(DicomVr.LOvr.MaximumLength, errorComment.Length));
            }

            SendDimse(presentationID, msg.CommandSet, null);
        }

Same methods

NetworkBase::SendCStoreResponse ( byte presentationID, ushort messageID, string affectedInstance, ClearCanvas.Dicom.Network.DicomStatus status ) : void