Creating new dicom elements using DicomWriter
I'm using the DicomWriter functionality to replace or remove dicom elements from an dicom object, which is working very good.
But now I like to add a new dicom element with a specific value. How can I do that? Using the 'replace' functionality does not work. As far as I can see, the algorithm just iterates over the existing dicom elements and therefore is not able to create new tags. I also tried to create a new dicomElement and pass it to the getBuffer method, but it always fails with an error message like "RangeError: Offset is outside the bounds of the DataView". Maybe due to the wrong offsets.
So is there a way to add new dicom elements during the getBuffer() operation?
Hi, sorry for the late reply. No, there is no way to add new elements but it seems doable. Any help appreciated!