我是 Fo-Dicom 的新手,我正在尝试在 Dicom Dump 中调用我的 output.dcm 文件,我正在尝试使用 fo-dicom 添加私有标签
string filename = "output.dcm";
DicomDataset ds = new DicomDataset(); //Main dataset
ds.Add(DicomTag.SpecificCharacterSet, txtCharacherSet.Text);
//Add some items
ds.Add(DicomTag.PatientID, txtid.Text);
ds.Add(DicomTag.PatientName, txtname.Text);
DicomDataset sqContent = new DicomDataset();
//Content of the sequence
sqContent.Add(DicomTag.Modality, txtModality.Text);
sqContent.Add(DicomTag.ScheduledProcedureStepStartDate,
DateTime.Now.Date);
DicomSequence sq = new
DicomSequence(DicomTag.ScheduledProcedureStepSequence, sqContent);
// Create sequence, add content
ds.Add(sq); //Add sequence to main dataset
DicomFile file = new DicomFile();
file.Dataset.Add(ds); //Add main dataset to DicomFile
file.FileMetaInfo.TransferSyntax =
DicomTransferSyntax.ImplicitVRLittleEndian;
//Specify transfer syntax
file.Save(filename); //Save file to disk
此代码运行良好,但我的私人标签未以显示形式显示。