Discussion Forum for OFFIS DICOM Tools - For registration, send email with desired user name to the OFFIS DICOM team
It is currently Fri, 2017-07-21, 15:52

All times are UTC + 1 hour

Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Sun, 2017-04-02, 05:28 

Joined: Mon, 2014-03-03, 09:53
Posts: 5
Hi Members,

I am trying to add private tags in exiting dicom file using DCMTK V3.6.
I have found some stuff after finding the string "Howto: Add private data elements to a DICOM dataset" and using the same in my code..
Private creator tag writing successful but getting error as below
"ERROR 0001:0007 Illegal call, perhaps wrong parameter" while writing private tags(tag1,tag2).

I have created private dictionary and tag writing code as below.

DcmDataDictionary &dict = dcmDataDict.wrlock();

DcmFileFormat inFile;
DcmDataset *dset = inFile.getDataset();

if (!dset->tagExists(DcmTag(0x0029, 0x0010))) //private creator exists
dset->putAndInsertString(DcmTag(0x0029, 0x0010,EVR_LO), "mycomp"); //private creator

DcmTag tag1(0x0029, 0x1023);
dset->putAndInsertString(tag1, "T1"); //private tag writing

DcmTag tag2(0x0029, 0x1027);
dset->putAndInsertString(tag2, "T2"); //private tag writing



Private Dictionary:
(0029,"mycomp",1023) LO Unknown 1
(0029,"mycomp",1027) DS Unknown 1


Please help me to resolve the above query.

Thanks & Regards

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 1 hour

Who is online

Users browsing this forum: Bing [Bot] and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group