Answering my own question, as this is mostly answered in another KB articule, but putting them in a table "seams" best and then you can build your new XML as so (assuming your table has Item,Value,Enabled columns)
// See what tables we have
var oTableName = qie.getVariable('tablename');
// Get our Table (ReportMsg/ControlFileHeader)
var oTableCSV = qie.parseCSVString(oTableName, true, '"', ',', true);
for (var iCount=0; iCount < oTableCSV.getRowCount(); iCount++) {
if (oTableCSV.getNode('Enabled', iCount+1) == 'True') {
sItem=oTableCSV.getNode('Item', iCount+1);
sValue=oTableCSV.getNode('Value', iCount+1);
qie.debug(sItem + '=' + sValue);
// Put into our XML object
message.setNode(sPrefix + sItem, sValue);
}
}