IMPORT com IMPORT XML IMPORT os FUNCTION aprobacion(req) # DEFINE doc xml.DomDocument DEFINE req com.HttpServiceRequest, doc XML.DomDocument DEFINE cmd,tmpfile STRING LET cmd = req.readFileRequest() DISPLAY "request: ",cmd LET doc = xml.DomDocument.Create() CALL doc.setFeature("whitespace-in-element-content",FALSE) TRY LET tmpfile = os.Path.baseName(cmd),'.',os.Path.extension(cmd) LET tmpfile = "./recibidos/aprobacioncomercial/",tmpfile CLIPPED CALL doc.load(cmd) CALL doc.save(tmpfile) RETURN 200,"Satisfactorio" CATCH RETURN 400,"insastisfactorio" END TRY END FUNCTION