XML-improvements, prepare sending