I have a DcmDataSet (ds) object and I am trying to edit some tag values in my code and I am using methods like:
Code: Select all
putAndInsertOFStringArray
putAndInsertString
putAndInsertUint16
putAndInsertFloat64
putAndInsertUint16Array
Now, before I call any of these methods, should I call ds->remove(TAG_IDENTIFIER). I noticed this my accident when I saw some of the tags were not getting updated. For example, the following code does not update the tag value:
Code: Select all
ds->putAndInsertFloat64(DCM_RescaleSlope, 1.0);
However, doing:
Code: Select all
ds->remove(DCM_RescaleSlope);
ds->putAndInsertFloat64(DCM_RescaleSlope, 1.0);
does the trick. So, should remove() be called before using any of the putAndInsertXXX methods?
Thanks!