Index: trunk/src/scriptbuilder/structures/TimeSlice.java
===================================================================
--- trunk/src/scriptbuilder/structures/TimeSlice.java	(revision 176)
+++ trunk/src/scriptbuilder/structures/TimeSlice.java	(revision 203)
@@ -225,14 +225,14 @@
         }
 
-        String output = XMLWriter.openTag(ELEMENT.SCRIPT_EVENT.tag);
+        String output = XMLBuilder.openTag(ELEMENT.SCRIPT_EVENT.tag);
         SimpleDateFormat df = new SimpleDateFormat("HH:mm:ss");
         df.setTimeZone(TimeZone.getTimeZone("GMT"));
         // Build the output string, starting with a newline (ticket #203)
-        output += "\n" + XMLWriter.openTag(ELEMENT.TIME_INDEX.tag) + df.format(new Date(seconds * 1000))
-                + XMLWriter.closeTag(ELEMENT.TIME_INDEX.tag);
-
-        output += XMLWriter.openTag(ELEMENT.INCIDENT.tag + " LogNum=\"" + thisIncident.number + "\"");
-        output += thisIncident.name + XMLWriter.closeTag(ELEMENT.INCIDENT.tag);
-        output += XMLWriter.emptyTag(ELEMENT.COLOR.tag
+        output += "\n" + XMLBuilder.openTag(ELEMENT.TIME_INDEX.tag) + df.format(new Date(seconds * 1000))
+                + XMLBuilder.closeTag(ELEMENT.TIME_INDEX.tag);
+
+        output += XMLBuilder.openTag(ELEMENT.INCIDENT.tag + " LogNum=\"" + thisIncident.number + "\"");
+        output += thisIncident.name + XMLBuilder.closeTag(ELEMENT.INCIDENT.tag);
+        output += XMLBuilder.emptyTag(ELEMENT.COLOR.tag
                 + " r=\"" + thisIncident.color.getRed() + "\""
                 + " g=\"" + thisIncident.color.getGreen() + "\""
@@ -241,5 +241,5 @@
         if ((cadData != null && cadData.hasCadData()) || containsCADIncidentEvent())
         {
-            output += XMLWriter.openTag(ELEMENT.CAD_DATA.tag);
+            output += XMLBuilder.openTag(ELEMENT.CAD_DATA.tag);
             if (cadData != null)
             {
@@ -249,5 +249,5 @@
             if (containsCADIncidentEvent())
             {
-                output += XMLWriter.openTag(ELEMENT.CAD_INCIDENT_EVENT.tag);
+                output += XMLBuilder.openTag(ELEMENT.CAD_INCIDENT_EVENT.tag);
                 for (I_ScriptEvent ev : eventsCopy)
                 {
@@ -264,19 +264,19 @@
 
                 eventsCopy = eventsCopy2;
-                output += XMLWriter.closeTag(ELEMENT.CAD_INCIDENT_EVENT.tag);
-            }
-
-            output += XMLWriter.closeTag(ELEMENT.CAD_DATA.tag);
+                output += XMLBuilder.closeTag(ELEMENT.CAD_INCIDENT_EVENT.tag);
+            }
+
+            output += XMLBuilder.closeTag(ELEMENT.CAD_DATA.tag);
         }
 
         if (cadData != null && cadData.hasGeneralInfo())
         {
-            output += XMLWriter.openTag(ELEMENT.GENERAL_INFO.tag);
-
-            output += XMLWriter.simpleTag(cadData.General_Title, ELEMENT.TITLE);
-
-            output += XMLWriter.simpleTag(cadData.General_Text, ELEMENT.TEXT);
-
-            output += XMLWriter.closeTag(ELEMENT.GENERAL_INFO.tag);
+            output += XMLBuilder.openTag(ELEMENT.GENERAL_INFO.tag);
+
+            output += XMLBuilder.simpleTag(cadData.General_Title, ELEMENT.TITLE);
+
+            output += XMLBuilder.simpleTag(cadData.General_Text, ELEMENT.TEXT);
+
+            output += XMLBuilder.closeTag(ELEMENT.GENERAL_INFO.tag);
 
         }
@@ -290,5 +290,5 @@
             }
         }
-        output += XMLWriter.closeTag(ELEMENT.SCRIPT_EVENT.tag);
+        output += XMLBuilder.closeTag(ELEMENT.SCRIPT_EVENT.tag);
         return output;
     }
Index: trunk/src/scriptbuilder/structures/CadData.java
===================================================================
--- trunk/src/scriptbuilder/structures/CadData.java	(revision 145)
+++ trunk/src/scriptbuilder/structures/CadData.java	(revision 203)
@@ -82,71 +82,71 @@
         if (!Master_Inc_Num.equals(""))
         {
-            output += XMLWriter.simpleTag(Master_Inc_Num, ELEMENT.MASTER_INC_NUM);
+            output += XMLBuilder.simpleTag(Master_Inc_Num, ELEMENT.MASTER_INC_NUM);
         }
 
         if (!P.equals(""))
         {
-            output += XMLWriter.simpleTag(P, ELEMENT.P);
+            output += XMLBuilder.simpleTag(P, ELEMENT.P);
         }
 
         if (hasAdditionalInfo())
         {
-            output += XMLWriter.openTag(ELEMENT.ADDITIONAL_INFO.tag);
-            output += XMLWriter.simpleTag(Info_Type_Code, ELEMENT.TYPE_CODE);
-            output += XMLWriter.simpleTag(Info_Type, ELEMENT.TYPE);
-            output += XMLWriter.closeTag(ELEMENT.ADDITIONAL_INFO.tag);
+            output += XMLBuilder.openTag(ELEMENT.ADDITIONAL_INFO.tag);
+            output += XMLBuilder.simpleTag(Info_Type_Code, ELEMENT.TYPE_CODE);
+            output += XMLBuilder.simpleTag(Info_Type, ELEMENT.TYPE);
+            output += XMLBuilder.closeTag(ELEMENT.ADDITIONAL_INFO.tag);
         }
 
         if (hasLocation())
         {
-            output += XMLWriter.openTag(ELEMENT.LOCATION.tag);
+            output += XMLBuilder.openTag(ELEMENT.LOCATION.tag);
             if (!Location_Beat.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_Beat, ELEMENT.BEAT);
+                output += XMLBuilder.simpleTag(Location_Beat, ELEMENT.BEAT);
             }
 
             if (!Location_Address.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_Address, ELEMENT.ADDRESS);
+                output += XMLBuilder.simpleTag(Location_Address, ELEMENT.ADDRESS);
             }
 
             if (!Location_Loc.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_Loc, ELEMENT.LOC);
+                output += XMLBuilder.simpleTag(Location_Loc, ELEMENT.LOC);
             }
 
             if (!Location_City.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_City, ELEMENT.CITY);
+                output += XMLBuilder.simpleTag(Location_City, ELEMENT.CITY);
             }
 
             if (!Location_Area.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_Area, ELEMENT.AREA);
+                output += XMLBuilder.simpleTag(Location_Area, ELEMENT.AREA);
             }
 
             if (!Location_Fire.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_Fire, ELEMENT.FIRE);
+                output += XMLBuilder.simpleTag(Location_Fire, ELEMENT.FIRE);
             }
 
             if (!Location_Law.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_Law, ELEMENT.LAW);
+                output += XMLBuilder.simpleTag(Location_Law, ELEMENT.LAW);
             }
 
             if (!Location_Ems.equals(""))
             {
-                output += XMLWriter.simpleTag(Location_Ems, ELEMENT.EMS);
-            }
-
-            output += XMLWriter.closeTag(ELEMENT.LOCATION.tag);
+                output += XMLBuilder.simpleTag(Location_Ems, ELEMENT.EMS);
+            }
+
+            output += XMLBuilder.closeTag(ELEMENT.LOCATION.tag);
         }
 
         if (!Agy.equals(""))
         {
-            output += XMLWriter.openTag(ELEMENT.GENERAL.tag);
-            output += XMLWriter.simpleTag(Agy, ELEMENT.AGY);
-            output += XMLWriter.closeTag(ELEMENT.GENERAL.tag);
+            output += XMLBuilder.openTag(ELEMENT.GENERAL.tag);
+            output += XMLBuilder.simpleTag(Agy, ELEMENT.AGY);
+            output += XMLBuilder.closeTag(ELEMENT.GENERAL.tag);
         }
 
@@ -154,15 +154,15 @@
         {
             //todo: make this logic trigger only once per incident
-            output += XMLWriter.openTag(ELEMENT.HEADER_INFO.tag);
-
-            output += XMLWriter.simpleTag(Header_Type, ELEMENT.Type);
-
-            output += XMLWriter.simpleTag(Header_Beat, ELEMENT.Beat);
-
-            output += XMLWriter.simpleTag(Header_TruncLoc, ELEMENT.TruncLoc);
-
-            output += XMLWriter.simpleTag(Header_FullLoc, ELEMENT.FullLoc);
-
-            output += XMLWriter.closeTag(ELEMENT.HEADER_INFO.tag);
+            output += XMLBuilder.openTag(ELEMENT.HEADER_INFO.tag);
+
+            output += XMLBuilder.simpleTag(Header_Type, ELEMENT.Type);
+
+            output += XMLBuilder.simpleTag(Header_Beat, ELEMENT.Beat);
+
+            output += XMLBuilder.simpleTag(Header_TruncLoc, ELEMENT.TruncLoc);
+
+            output += XMLBuilder.simpleTag(Header_FullLoc, ELEMENT.FullLoc);
+
+            output += XMLBuilder.closeTag(ELEMENT.HEADER_INFO.tag);
         }
 
Index: trunk/src/scriptbuilder/structures/ScriptIncident.java
===================================================================
--- trunk/src/scriptbuilder/structures/ScriptIncident.java	(revision 201)
+++ trunk/src/scriptbuilder/structures/ScriptIncident.java	(revision 203)
@@ -413,6 +413,6 @@
     {
         String output = "<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>\n";
-        output += XMLWriter.externalDTD();
-        output += XMLWriter.openTag(ELEMENT.TMC_SCRIPT.tag + " title=\"" + this.script.title + "\"");
+        output += XMLBuilder.externalDTD();
+        output += XMLBuilder.openTag(ELEMENT.TMC_SCRIPT.tag + " title=\"" + this.script.title + "\"");
 
         for (TimeSlice slice : slices.values())
@@ -420,5 +420,5 @@
             output += slice.toXML();
         }
-        output += XMLWriter.closeTag(ELEMENT.TMC_SCRIPT.tag);
+        output += XMLBuilder.closeTag(ELEMENT.TMC_SCRIPT.tag);
         return output;
     }
Index: trunk/src/scriptbuilder/structures/units/Unit.java
===================================================================
--- trunk/src/scriptbuilder/structures/units/Unit.java	(revision 145)
+++ trunk/src/scriptbuilder/structures/units/Unit.java	(revision 203)
@@ -8,5 +8,5 @@
 import scriptbuilder.structures.ELEMENT;
 import scriptbuilder.structures.I_XML_Writable;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -113,98 +113,98 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.NEW_UNIT.tag + " UnitNum=\"" + UnitNum + "\"");
+        String output = XMLBuilder.openTag(ELEMENT.NEW_UNIT.tag + " UnitNum=\"" + UnitNum + "\"");
 
         if (!ID.equals(""))
         {
-            output += XMLWriter.simpleTag(ID, ELEMENT.ID);
+            output += XMLBuilder.simpleTag(ID, ELEMENT.ID);
         }
 
         if (!Status.equals(""))
         {
-            output += XMLWriter.simpleTag(Status, ELEMENT.STATUS);
+            output += XMLBuilder.simpleTag(Status, ELEMENT.STATUS);
         }
 
         if (!Master_Inc_Num.equals(""))
         {
-            output += XMLWriter.simpleTag(Master_Inc_Num, ELEMENT.MASTER_INC_NUM);
+            output += XMLBuilder.simpleTag(Master_Inc_Num, ELEMENT.MASTER_INC_NUM);
         }
 
         if (!Primary.equals(""))
         {
-            output += XMLWriter.simpleTag(Primary, ELEMENT.PRIMARY);
+            output += XMLBuilder.simpleTag(Primary, ELEMENT.PRIMARY);
         }
 
         if (!OOS.equals(""))
         {
-            output += XMLWriter.simpleTag(OOS, ELEMENT.OOS);
+            output += XMLBuilder.simpleTag(OOS, ELEMENT.OOS);
         }
 
         if (!Type.equals(""))
         {
-            output += XMLWriter.simpleTag(Type, ELEMENT.TYPE);
+            output += XMLBuilder.simpleTag(Type, ELEMENT.TYPE);
         }
 
         //All units have a current location field, even if it's blank
-        output += XMLWriter.simpleTag(Curr_Loc, ELEMENT.CURR_LOC);
+        output += XMLBuilder.simpleTag(Curr_Loc, ELEMENT.CURR_LOC);
 
         //All units have a destination field, even if it's blank
-        output += XMLWriter.simpleTag(Destination, ELEMENT.DESTINATION);
+        output += XMLBuilder.simpleTag(Destination, ELEMENT.DESTINATION);
 
         if (!Misc_Info.equals(""))
         {
-            output += XMLWriter.simpleTag(Misc_Info, ELEMENT.MISC_INFO);
+            output += XMLBuilder.simpleTag(Misc_Info, ELEMENT.MISC_INFO);
         }
 
         if (!Stack.equals(""))
         {
-            output += XMLWriter.simpleTag(Stack, ELEMENT.STACK);
+            output += XMLBuilder.simpleTag(Stack, ELEMENT.STACK);
         }
 
         if (!Area.equals(""))
         {
-            output += XMLWriter.simpleTag(Area, ELEMENT.AREA);
+            output += XMLBuilder.simpleTag(Area, ELEMENT.AREA);
         }
 
         if (!Badge_Num.equals(""))
         {
-            output += XMLWriter.simpleTag(Badge_Num, ELEMENT.BADGE_NUM);
+            output += XMLBuilder.simpleTag(Badge_Num, ELEMENT.BADGE_NUM);
         }
 
         if (!Officer.equals(""))
         {
-            output += XMLWriter.simpleTag(Officer, ELEMENT.OFFICER);
+            output += XMLBuilder.simpleTag(Officer, ELEMENT.OFFICER);
         }
 
         if (!Office.equals(""))
         {
-            output += XMLWriter.simpleTag(Office, ELEMENT.OFFICE);
+            output += XMLBuilder.simpleTag(Office, ELEMENT.OFFICE);
         }
 
         if (!Timer.equals(""))
         {
-            output += XMLWriter.simpleTag(Timer, ELEMENT.TIMER);
+            output += XMLBuilder.simpleTag(Timer, ELEMENT.TIMER);
         }
 
         if (!P.equals(""))
         {
-            output += XMLWriter.simpleTag(P, ELEMENT.P);
+            output += XMLBuilder.simpleTag(P, ELEMENT.P);
         }
 
         if (!Agy.equals(""))
         {
-            output += XMLWriter.simpleTag(Agy, ELEMENT.AGY);
+            output += XMLBuilder.simpleTag(Agy, ELEMENT.AGY);
         }
 
         if (!Alias.equals(""))
         {
-            output += XMLWriter.simpleTag(Alias, ELEMENT.ALIAS);
+            output += XMLBuilder.simpleTag(Alias, ELEMENT.ALIAS);
         }
 
         if (!Unit_Status.equals(""))
         {
-            output += XMLWriter.simpleTag(Unit_Status, ELEMENT.UNIT_STATUS);
-        }
-
-        output += XMLWriter.closeTag(ELEMENT.NEW_UNIT.tag);
+            output += XMLBuilder.simpleTag(Unit_Status, ELEMENT.UNIT_STATUS);
+        }
+
+        output += XMLBuilder.closeTag(ELEMENT.NEW_UNIT.tag);
         return output;
     }
Index: trunk/src/scriptbuilder/structures/Location_Info.java
===================================================================
--- trunk/src/scriptbuilder/structures/Location_Info.java	(revision 46)
+++ trunk/src/scriptbuilder/structures/Location_Info.java	(revision 203)
@@ -21,15 +21,15 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.LOCATION_INFO.tag + " ID=\"" + Location_ID + "\"");
+        String output = XMLBuilder.openTag(ELEMENT.LOCATION_INFO.tag + " ID=\"" + Location_ID + "\"");
 
-        output += XMLWriter.simpleTag(Route, ELEMENT.Route);
+        output += XMLBuilder.simpleTag(Route, ELEMENT.Route);
 
-        output += XMLWriter.simpleTag(Direction, ELEMENT.Direction);
+        output += XMLBuilder.simpleTag(Direction, ELEMENT.Direction);
 
-        output += XMLWriter.simpleTag(Postmile, ELEMENT.Postmile);
+        output += XMLBuilder.simpleTag(Postmile, ELEMENT.Postmile);
 
-        output += XMLWriter.simpleTag(Location_type, ELEMENT.Location_type);
+        output += XMLBuilder.simpleTag(Location_type, ELEMENT.Location_type);
 
-        output += XMLWriter.closeTag(ELEMENT.LOCATION_INFO.tag);
+        output += XMLBuilder.closeTag(ELEMENT.LOCATION_INFO.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/WitnessEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/WitnessEvent.java	(revision 46)
+++ trunk/src/scriptbuilder/structures/events/WitnessEvent.java	(revision 203)
@@ -9,5 +9,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -37,5 +37,5 @@
     public String toXML()
     {
-        return XMLWriter.emptyTag(ELEMENT.WITNESS.tag + " Name=\"" + witnessName + "\" Address=\""
+        return XMLBuilder.emptyTag(ELEMENT.WITNESS.tag + " Name=\"" + witnessName + "\" Address=\""
                 + witnessAddress + "\" PhoneNum=\"" + witnessNum + "\"");
     }
Index: trunk/src/scriptbuilder/structures/events/ATMSEvaluationEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/ATMSEvaluationEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/ATMSEvaluationEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -60,5 +60,5 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.ATMS_EVALUATION.tag);
+        String output = XMLBuilder.openTag(ELEMENT.ATMS_EVALUATION.tag);
         if (expectedAction != null)
         {
@@ -69,8 +69,8 @@
                     str = "";
                 }
-                output += XMLWriter.simpleTag(str, ELEMENT.EXPECTED_ACTION);
+                output += XMLBuilder.simpleTag(str, ELEMENT.EXPECTED_ACTION);
             }
         }
-        output += XMLWriter.closeTag(ELEMENT.ATMS_EVALUATION.tag);
+        output += XMLBuilder.closeTag(ELEMENT.ATMS_EVALUATION.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/CCTVEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/CCTVEvent.java	(revision 153)
+++ trunk/src/scriptbuilder/structures/events/CCTVEvent.java	(revision 203)
@@ -9,5 +9,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
Index: trunk/src/scriptbuilder/structures/events/ParamicsEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/ParamicsEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/ParamicsEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -40,18 +40,18 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.PARAMICS.tag + " LocationID=\"" + locationID + "\"");
+        String output = XMLBuilder.openTag(ELEMENT.PARAMICS.tag + " LocationID=\"" + locationID + "\"");
 
-        output += XMLWriter.simpleTag(status, ELEMENT.Status);
+        output += XMLBuilder.simpleTag(status, ELEMENT.Status);
 
         if (!type.equals(""))
         {
-            output += XMLWriter.simpleTag(type, ELEMENT.Incident_type);
+            output += XMLBuilder.simpleTag(type, ELEMENT.Incident_type);
         }
 
         for (Integer lane : laneNums)
         {
-            output += XMLWriter.simpleTag("" + lane, ELEMENT.Lane_number);
+            output += XMLBuilder.simpleTag("" + lane, ELEMENT.Lane_number);
         }
-        output += XMLWriter.closeTag(ELEMENT.PARAMICS.tag);
+        output += XMLBuilder.closeTag(ELEMENT.PARAMICS.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/AudioEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/AudioEvent.java	(revision 167)
+++ trunk/src/scriptbuilder/structures/events/AudioEvent.java	(revision 203)
@@ -9,5 +9,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -75,5 +75,5 @@
     public String toXML()
     {
-        return XMLWriter.emptyTag(ELEMENT.AUDIO.tag + " Length=\"" + audioLength + "\" Path=\"" + audioPath + "\"");
+        return XMLBuilder.emptyTag(ELEMENT.AUDIO.tag + " Length=\"" + audioLength + "\" Path=\"" + audioPath + "\"");
     }
 }
Index: trunk/src/scriptbuilder/structures/events/MaintenanceRadioEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/MaintenanceRadioEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/MaintenanceRadioEvent.java	(revision 203)
@@ -9,5 +9,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -33,5 +33,5 @@
     public String toXML()
     {
-        String output = XMLWriter.simpleTag(message, ELEMENT.MAINTENANCE_RADIO);
+        String output = XMLBuilder.simpleTag(message, ELEMENT.MAINTENANCE_RADIO);
         return output;
     }
Index: trunk/src/scriptbuilder/structures/events/TowEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/TowEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/TowEvent.java	(revision 203)
@@ -9,5 +9,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -39,5 +39,5 @@
     public String toXML()
     {
-        return XMLWriter.emptyTag(ELEMENT.TOW.tag + " Company=\"" + towCompany + "\" ConfNum=\""
+        return XMLBuilder.emptyTag(ELEMENT.TOW.tag + " Company=\"" + towCompany + "\" ConfNum=\""
                 + towConfNum + "\" PubNum=\"" + towPubNum + "\" Beat=\"" + towBeat + "\"");
     }
Index: trunk/src/scriptbuilder/structures/events/CMSEvaluationEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/CMSEvaluationEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/CMSEvaluationEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -66,10 +66,10 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.CMS_EVALUATION.tag + " cmsID=\"" + cmsID + "\" type=\"" + cmsType + "\"");
-        output += XMLWriter.simpleTag(location, ELEMENT.LOCATION);
+        String output = XMLBuilder.openTag(ELEMENT.CMS_EVALUATION.tag + " cmsID=\"" + cmsID + "\" type=\"" + cmsType + "\"");
+        output += XMLBuilder.simpleTag(location, ELEMENT.LOCATION);
 
         if (message.size() > 0)
         {
-            output += XMLWriter.openTag(ELEMENT.SAMPLE_MESSAGE.tag);
+            output += XMLBuilder.openTag(ELEMENT.SAMPLE_MESSAGE.tag);
             for (String str : message)
             {
@@ -78,10 +78,10 @@
                     str = "";
                 }
-                output += XMLWriter.simpleTag(str, ELEMENT.CMS_LINE);
+                output += XMLBuilder.simpleTag(str, ELEMENT.CMS_LINE);
             }
-            output += XMLWriter.closeTag(ELEMENT.SAMPLE_MESSAGE.tag);
+            output += XMLBuilder.closeTag(ELEMENT.SAMPLE_MESSAGE.tag);
         }
 
-        output += XMLWriter.closeTag(ELEMENT.CMS_EVALUATION.tag);
+        output += XMLBuilder.closeTag(ELEMENT.CMS_EVALUATION.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/CADEvaluationEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/CADEvaluationEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/CADEvaluationEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -60,5 +60,5 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.CAD_EVALUATION.tag);
+        String output = XMLBuilder.openTag(ELEMENT.CAD_EVALUATION.tag);
         if (expectedAction != null)
         {
@@ -69,8 +69,8 @@
                     str = "";
                 }
-                output += XMLWriter.simpleTag(str, ELEMENT.EXPECTED_ACTION);
+                output += XMLBuilder.simpleTag(str, ELEMENT.EXPECTED_ACTION);
             }
         }
-        output += XMLWriter.closeTag(ELEMENT.CAD_EVALUATION.tag);
+        output += XMLBuilder.closeTag(ELEMENT.CAD_EVALUATION.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/UnitEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/UnitEvent.java	(revision 145)
+++ trunk/src/scriptbuilder/structures/events/UnitEvent.java	(revision 203)
@@ -9,5 +9,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -41,5 +41,5 @@
     public String toXML()
     {
-        return XMLWriter.emptyTag(ELEMENT.UNIT.tag+" UnitNum=\""+unitNum+"\" Status=\""
+        return XMLBuilder.emptyTag(ELEMENT.UNIT.tag+" UnitNum=\""+unitNum+"\" Status=\""
                 +unitStatus+"\" Primary=\""+unitPrimary+"\" Active=\""+unitActive+"\"");
     }
Index: trunk/src/scriptbuilder/structures/events/TMTRadioEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/TMTRadioEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/TMTRadioEvent.java	(revision 203)
@@ -9,5 +9,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -33,5 +33,5 @@
     public String toXML()
     {
-        String output = XMLWriter.simpleTag(message, ELEMENT.TMT_RADIO);
+        String output = XMLBuilder.simpleTag(message, ELEMENT.TMT_RADIO);
         return output;
     }
Index: trunk/src/scriptbuilder/structures/events/TelephoneEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/TelephoneEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/TelephoneEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -37,19 +37,19 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.TELEPHONE.tag);
+        String output = XMLBuilder.openTag(ELEMENT.TELEPHONE.tag);
         for (int i = 0; i < lines.size(); i++)
         {
             if (roles.get(i).equalsIgnoreCase(ELEMENT.STUDENT.tag))
             {
-                output += XMLWriter.simpleTag(lines.get(i), ELEMENT.STUDENT);
+                output += XMLBuilder.simpleTag(lines.get(i), ELEMENT.STUDENT);
             }
             else
             {
-                output += XMLWriter.openTag(ELEMENT.INSTRUCTOR.tag + " Role=\"" + roles.get(i) + "\"");
+                output += XMLBuilder.openTag(ELEMENT.INSTRUCTOR.tag + " Role=\"" + roles.get(i) + "\"");
                 output += lines.get(i);
-                output += XMLWriter.closeTag(ELEMENT.INSTRUCTOR.tag);
+                output += XMLBuilder.closeTag(ELEMENT.INSTRUCTOR.tag);
             }
         }
-        output += XMLWriter.closeTag(ELEMENT.TELEPHONE.tag);
+        output += XMLBuilder.closeTag(ELEMENT.TELEPHONE.tag);
         return output;
     }
Index: trunk/src/scriptbuilder/structures/events/ActivityLogEvaluationEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/ActivityLogEvaluationEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/ActivityLogEvaluationEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -60,5 +60,5 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.ACTIVITY_LOG_EVALUATION.tag);
+        String output = XMLBuilder.openTag(ELEMENT.ACTIVITY_LOG_EVALUATION.tag);
         if (expectedAction != null)
         {
@@ -69,8 +69,8 @@
                     str = "";
                 }
-                output += XMLWriter.simpleTag(str, ELEMENT.EXPECTED_ACTION);
+                output += XMLBuilder.simpleTag(str, ELEMENT.EXPECTED_ACTION);
             }
         }
-        output += XMLWriter.closeTag(ELEMENT.ACTIVITY_LOG_EVALUATION.tag);
+        output += XMLBuilder.closeTag(ELEMENT.ACTIVITY_LOG_EVALUATION.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/RadioEvaluationEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/RadioEvaluationEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/RadioEvaluationEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -60,5 +60,5 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.RADIO_EVALUATION.tag);
+        String output = XMLBuilder.openTag(ELEMENT.RADIO_EVALUATION.tag);
         if (expectedAction != null)
         {
@@ -69,8 +69,8 @@
                     str = "";
                 }
-                output += XMLWriter.simpleTag(str, ELEMENT.EXPECTED_ACTION);
+                output += XMLBuilder.simpleTag(str, ELEMENT.EXPECTED_ACTION);
             }
         }
-        output += XMLWriter.closeTag(ELEMENT.RADIO_EVALUATION.tag);
+        output += XMLBuilder.closeTag(ELEMENT.RADIO_EVALUATION.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/CADEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/CADEvent.java	(revision 185)
+++ trunk/src/scriptbuilder/structures/events/CADEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -46,5 +46,5 @@
         while (tok.hasMoreTokens())
         {
-            output += XMLWriter.simpleTag(tok.nextToken(), ELEMENT.DETAIL);
+            output += XMLBuilder.simpleTag(tok.nextToken(), ELEMENT.DETAIL);
         }
         return output;
Index: trunk/src/scriptbuilder/structures/events/CHPRadioEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/CHPRadioEvent.java	(revision 175)
+++ trunk/src/scriptbuilder/structures/events/CHPRadioEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -101,16 +101,16 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.CHP_RADIO.tag + " RadioFile=\"" + radioFile + "\"");
-        output += XMLWriter.openTag(ELEMENT.DIALOG.tag);
+        String output = XMLBuilder.openTag(ELEMENT.CHP_RADIO.tag + " RadioFile=\"" + radioFile + "\"");
+        output += XMLBuilder.openTag(ELEMENT.DIALOG.tag);
 
         for (int i = 0; i < lines.size(); i++)
         {
-            output += XMLWriter.openTag(ELEMENT.LINE.tag + " Role=\"" + roles.get(i) + "\"");
+            output += XMLBuilder.openTag(ELEMENT.LINE.tag + " Role=\"" + roles.get(i) + "\"");
             output += lines.get(i);
-            output += XMLWriter.closeTag(ELEMENT.LINE.tag);
+            output += XMLBuilder.closeTag(ELEMENT.LINE.tag);
         }
 
-        output += XMLWriter.closeTag(ELEMENT.DIALOG.tag);
-        output += XMLWriter.closeTag(ELEMENT.CHP_RADIO.tag);
+        output += XMLBuilder.closeTag(ELEMENT.DIALOG.tag);
+        output += XMLBuilder.closeTag(ELEMENT.CHP_RADIO.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/events/FacilitatorEvaluationEvent.java
===================================================================
--- trunk/src/scriptbuilder/structures/events/FacilitatorEvaluationEvent.java	(revision 76)
+++ trunk/src/scriptbuilder/structures/events/FacilitatorEvaluationEvent.java	(revision 203)
@@ -10,5 +10,5 @@
 import scriptbuilder.structures.I_XML_Writable;
 import scriptbuilder.structures.ScriptEvent;
-import scriptbuilder.structures.XMLWriter;
+import scriptbuilder.structures.XMLBuilder;
 
 /**
@@ -60,5 +60,5 @@
     public String toXML()
     {
-        String output = XMLWriter.openTag(ELEMENT.FACILITATOR_EVALUATION.tag);
+        String output = XMLBuilder.openTag(ELEMENT.FACILITATOR_EVALUATION.tag);
         if (expectedAction != null)
         {
@@ -69,8 +69,8 @@
                     str = "";
                 }
-                output += XMLWriter.simpleTag(str, ELEMENT.EXPECTED_ACTION);
+                output += XMLBuilder.simpleTag(str, ELEMENT.EXPECTED_ACTION);
             }
         }
-        output += XMLWriter.closeTag(ELEMENT.FACILITATOR_EVALUATION.tag);
+        output += XMLBuilder.closeTag(ELEMENT.FACILITATOR_EVALUATION.tag);
 
         return output;
Index: trunk/src/scriptbuilder/structures/XMLBuilder.java
===================================================================
--- trunk/src/scriptbuilder/structures/XMLBuilder.java	(revision 203)
+++ trunk/src/scriptbuilder/structures/XMLBuilder.java	(revision 203)
@@ -0,0 +1,162 @@
+package scriptbuilder.structures;
+
+import java.io.IOException;
+import java.io.StringReader;
+import java.io.StringWriter;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+import javax.xml.transform.OutputKeys;
+import javax.xml.transform.Transformer;
+import javax.xml.transform.TransformerException;
+import javax.xml.transform.TransformerFactory;
+import javax.xml.transform.dom.DOMSource;
+import javax.xml.transform.stream.StreamResult;
+import org.w3c.dom.Document;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * Utility methods that build XML elements from content strings.
+ * @author Bryan McGuffin
+ */
+public class XMLBuilder
+{
+
+    /**
+     * XML-style opening tag. Example: if given string "my_tag", returns
+     * "<my_tag>".
+     *
+     * @param s the XML element to be included in the tag.
+     * @return the properly formatted tag
+     */
+    public static String openTag(String s)
+    {
+        return "<" + s + ">";
+    }
+
+    /**
+     * XML-style closing tag. Example: if given string "my_tag", returns
+     * "</my_tag>".
+     *
+     * @param s the XML element to be included in the tag.
+     * @return the properly formatted tag
+     */
+    public static String closeTag(String s)
+    {
+        return "</" + s + ">\n";
+    }
+
+    /**
+     * XML-style empty tag. Example: if given string "my_tag", returns
+     * "<my_tag/>".
+     *
+     * @param s the XML element to be included in the tag.
+     * @return the properly formatted tag
+     */
+    public static String emptyTag(String s)
+    {
+        return "<" + s + "/>\n";
+    }
+
+    /**
+     * Creates a pair of XML open and close tags to wrap a simple line of data.
+     * Useful if only one element need be enclosed in this particular tag.
+     *
+     * @param s the data to be wrapped
+     * @param e the XML element represented by the data
+     * @return an XML string of the format <my_tag>some_data_goes_here</my_tag>
+     */
+    public static String simpleTag(String s, ELEMENT e)
+    {
+        String output = "";
+        if (s == null)
+        {
+            s = "";
+        }
+
+        output += openTag(e.tag);
+        output += s;
+        output += closeTag(e.tag);
+
+        return output;
+    }
+
+    /**
+     * Generates the link to external DTD for XML script files.
+     *
+     * @return
+     */
+    public static String externalDTD()
+    {
+        String output = "";
+        output += "<!DOCTYPE TMC_SCRIPT SYSTEM \"incident_script.dtd\">\n";
+        return output;
+    }
+    
+    /**
+     * Prettyprint an XML string.
+     * @param xmlString (works best if it contains no newlines)
+     * @return String that has been nicely formatted with indentation
+     */
+    public static String prettyPrintXML(String xmlString)
+    {
+        System.out.println("prettyprint start: " + xmlString);
+        Document xmlDoc = null;
+        String formattedXML = "";
+        try {
+            xmlDoc = toXmlDocument(xmlString);
+            formattedXML = prettyprintdoc(xmlDoc);
+        } catch (ParserConfigurationException | SAXException | IOException
+                | TransformerException e) {
+            e.printStackTrace();
+        }
+        return formattedXML;
+    }
+    
+ 
+    /**
+     * Prettyprint an XML document.
+     * @param document an "ugly" XML document
+     * @return String nicely formatted XML with indentation
+     * @throws TransformerException 
+     */
+    public static String prettyprintdoc(Document document)
+            throws TransformerException {
+        TransformerFactory transformerFactory = TransformerFactory
+                .newInstance();
+        Transformer transformer = transformerFactory.newTransformer();
+        transformer.setOutputProperty(OutputKeys.INDENT, "yes");
+        transformer.setOutputProperty(
+                "{http://xml.apache.org/xslt}indent-amount", "2");
+        transformer.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, "yes");
+        DOMSource source = new DOMSource(document);
+        StringWriter strWriter = new StringWriter();
+        StreamResult result = new StreamResult(strWriter);
+ 
+        transformer.transform(source, result);
+ 
+        return strWriter.getBuffer().toString();
+ 
+    }
+ 
+    /** Create an XML Document from a string that is in xml format.
+     * 
+     * @param str xml format content
+     * @return Document containing the specified content.
+     * @throws ParserConfigurationException
+     * @throws SAXException
+     * @throws IOException 
+     */
+    public static Document toXmlDocument(String str)
+            throws ParserConfigurationException, SAXException, IOException {
+ 
+        DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory
+                .newInstance();
+        DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
+        Document document = docBuilder.parse(new InputSource(new StringReader(
+                str)));
+ 
+        return document;
+    }
+}
Index: trunk/src/scriptbuilder/structures/SimulationScript.java
===================================================================
--- trunk/src/scriptbuilder/structures/SimulationScript.java	(revision 201)
+++ trunk/src/scriptbuilder/structures/SimulationScript.java	(revision 203)
@@ -18,4 +18,5 @@
 import java.nio.file.Paths;
 import java.util.TreeMap;
+import static scriptbuilder.structures.XMLBuilder.prettyPrintXML;
 
 /**
@@ -249,8 +250,10 @@
 
             BufferedWriter bw = new BufferedWriter(new FileWriter(f));
-            bw.write(this.toXML());
+            // convert to XML and remove newlines
+            String xmlOut = (this.toXML()).replace("\n",""); 
+            // pretty print and save to file
+            bw.write(prettyPrintXML(xmlOut));
             bw.flush();
             bw.close();
-
         }
         catch (Exception ex)
@@ -358,15 +361,15 @@
         ArrayList<TimeSlice> slices = arrangeAllSlices();
         String output = "<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>\n";
-        output += XMLWriter.externalDTD();
-        output += XMLWriter.openTag(ELEMENT.TMC_SCRIPT.tag + " title=\"" + this.title + "\"");
+        output += XMLBuilder.externalDTD();
+        output += XMLBuilder.openTag(ELEMENT.TMC_SCRIPT.tag + " title=\"" + this.title + "\"");
 
         if (units.size() > 0)
         {
-            output += XMLWriter.openTag(ELEMENT.SCRIPT_DATA.tag);
+            output += XMLBuilder.openTag(ELEMENT.SCRIPT_DATA.tag);
             for (Unit unit : units)
             {
                 output += unit.toXML();
             }
-            output += XMLWriter.closeTag(ELEMENT.SCRIPT_DATA.tag);
+            output += XMLBuilder.closeTag(ELEMENT.SCRIPT_DATA.tag);
         }
         for (TimeSlice slice : slices)
@@ -374,5 +377,5 @@
             output += slice.toXML();
         }
-        output += XMLWriter.closeTag(ELEMENT.TMC_SCRIPT.tag);
+        output += XMLBuilder.closeTag(ELEMENT.TMC_SCRIPT.tag);
         return output;
     }
Index: trunk/src/scriptbuilder/structures/XMLWriter.java
===================================================================
--- trunk/src/scriptbuilder/structures/XMLWriter.java	(revision 201)
+++ 	(revision )
@@ -1,80 +1,0 @@
-package scriptbuilder.structures;
-
-/**
- *
- * @author Bryan McGuffin
- */
-public class XMLWriter
-{
-
-    /**
-     * XML-style opening tag. Example: if given string "my_tag", returns
-     * "<my_tag>".
-     *
-     * @param s the XML element to be included in the tag.
-     * @return the properly formatted tag
-     */
-    public static String openTag(String s)
-    {
-        return "<" + s + ">";
-    }
-
-    /**
-     * XML-style closing tag. Example: if given string "my_tag", returns
-     * "</my_tag>".
-     *
-     * @param s the XML element to be included in the tag.
-     * @return the properly formatted tag
-     */
-    public static String closeTag(String s)
-    {
-        return "</" + s + ">\n";
-    }
-
-    /**
-     * XML-style empty tag. Example: if given string "my_tag", returns
-     * "<my_tag/>".
-     *
-     * @param s the XML element to be included in the tag.
-     * @return the properly formatted tag
-     */
-    public static String emptyTag(String s)
-    {
-        return "<" + s + "/>\n";
-    }
-
-    /**
-     * Creates a pair of XML open and close tags to wrap a simple line of data.
-     * Useful if only one element need be enclosed in this particular tag.
-     *
-     * @param s the data to be wrapped
-     * @param e the XML element represented by the data
-     * @return an XML string of the format <my_tag>some_data_goes_here</my_tag>
-     */
-    public static String simpleTag(String s, ELEMENT e)
-    {
-        String output = "";
-        if (s == null)
-        {
-            s = "";
-        }
-
-        output += openTag(e.tag);
-        output += s;
-        output += closeTag(e.tag);
-
-        return output;
-    }
-
-    /**
-     * Generates the link to external DTD for XML script files.
-     *
-     * @return
-     */
-    public static String externalDTD()
-    {
-        String output = "";
-        output += "<!DOCTYPE TMC_SCRIPT SYSTEM \"incident_script.dtd\">\n";
-        return output;
-    }
-}
