Ok, quick and dirty, try this
s stream=##class(%FileBinaryStream).%New()
s stream.Filename = filename
s propertyPath = "PIDgrpgrp(1).ORCgrp(1).OBXgrp(1).OBX:5(1)"
s seg=target.GetMutableSegmentAt($P(propertyPath,":",1),.tSC)
s tSC = seg.StoreFieldStreamBase64(.stream,$P(propertyPath,":",2),,0)
set tSegString=""
set tSegStringCleared=""
set tSegString = target.GetValueAt("PIDgrpgrp(1).ORCgrp(1).OBXgrp(1).OBX:5(1)")
set tSegStringCleared = $translate(tSegString,$c(13,10))
set tSC = target.SetValueAt(tSegStringCleared,"target.{PIDgrpgrp(1).ORCgrp(1).OBXgrp(1).OBX:5(1)}","set")
I'll ask again so I understand you correctly.
You want to have another OBX segment with each CRLF or another OBX:5(*) field?
More segments would create too much overhead.
I think the IHE Radiology Profile recommends a new segment every 62k bit.
With repeated fields in OBX:5 it's not HL7 standard conform.
Or would you like an OBX:5 field with the value ABCDEFGHIJKL...







It's great that so much feedback comes together.
An advertised advantage of Atelier is the SCM functionality. How does this look like with VSCode? Is there a manual or examples? Are there differences between VSCode and Atelier?
Unfortunately, we have no experience with this yet.