Hab jetzt mal das Script und die Einstellungen von NMA in BM rauskopiert - sollte eigentlich passen ?
public static bool ProcessResponse(int httpCode, String[] header, String content, out String result) {
using (System.Xml.XmlReader reader = System.Xml.XmlReader.Create(new System.IO.StringReader(content))) {
while(reader.Read()) {
if (reader.NodeType == System.Xml.XmlNodeType.Element) {
if (reader.Name == "success") {
result = "OK, " + reader.GetAttribute("remaining") + " Nachrichten übrig";
return true;
} else if (reader.Name == "error") {
result = reader.ReadInnerXml() + "(" + reader.GetAttribute("code") + ")";
return false;
}
}
}
}
result = "";
return false;
}
public static void PrepareVariables(System.Collections.Generic.IDictionary<String, String> variables) {
String value;
if(! variables.TryGetValue("message", out value) || value == null || value.Trim().Length == 0)
variables["message"] = "Keine Meldung";
if(! variables.TryGetValue("title", out value) || value == null || value.Trim().Length == 0)
variables["title"] = "Kein Titel";
}
