web stats
How to clear out a field completely - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Thread Tools Display Modes
Old 04-27-2012, 03:44 AM
rutledj rutledj is offline
Mirth Guru
Join Date: Nov 2010
Posts: 242
rutledj is on a distinguished road
Default How to clear out a field completely

If I have the following


and I want to replace the ^ between the name with a space, how do I do that so in the end I'd have this:

NK1|1|Jane Doe|||555-555-5555||SON

Reply With Quote
Old 04-28-2012, 05:37 PM
nelson.wells nelson.wells is offline
OBX.1 Kenobi
Join Date: Sep 2010
Posts: 26
nelson.wells is on a distinguished road

Something like this should work

msg['NK1']['NK1.2']['NK1.2.1'] = msg['NK1']['NK1.2']['NK1.2.1'].toString() + msg['NK1']['NK1.2']['NK1.2.2'].toString();
msg['NK1']['NK1.2']['NK1.2.2'] = '';
So, basically, you'll want to assign the first sub-segment to the concatenation of the first sub-segment and the second sub-segment, and then blank out the second sub-segment.
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -8. The time now is 04:45 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2015, vBulletin Solutions, Inc.
Mirth Corporation