RPA RPA current warning kilometers last initialisation kilometers last warning RPA RPA Warnung aktuell Kilometerstand letzte Initialisierung Kilometerstand letzte Warnung tag in dieser form vorhanden sein: // Jedenfalls wurde bei meinen Tests die ExecuteJobs Funktion niemals aufgerufen wenn in der ccpage // jobs im normalen Format enthalten waren. Ob das wirklich so ist oder ich einen anderen Fehler hatte // muss ich erst noch rausfinden. public void CreateLayout(ActivityMain activity, JobReader.PageInfo pageInfo, LinearLayout pageLayout) { LinearLayout buttonLayout = new LinearLayout(activity); buttonLayout.Orientation = Orientation.Horizontal; LinearLayout.LayoutParams buttonLayoutParams = new LinearLayout.LayoutParams( ViewGroup.LayoutParams.MatchParent, ViewGroup.LayoutParams.WrapContent); buttonLayoutParams.Weight = 1; buttonRPAReset = new Button(activity); buttonRPAReset.Text = "RPA RESET"; buttonRPAReset.Click += delegate { // button setzt klassenweite variable auf true, diese wird beim durchlauf von ExecuteJob ausgewertet doRPAReset = true; // Benachrichtung anzeigen wenn man will ActivityMain.ShowNotification(activity, 0, 2, "RPA RESET", "Reifen Pannen Anzeige am DSC MK60 wird zurückgesetzt..."); }; buttonLayout.AddView(buttonRPAReset, buttonLayoutParams); LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams( ViewGroup.LayoutParams.MatchParent, ViewGroup.LayoutParams.WrapContent); pageLayout.AddView(buttonLayout, layoutParams); } public void DestroyLayout(JobReader.PageInfo pageInfo) { buttonRPAReset = null; } public void UpdateLayout(JobReader.PageInfo pageInfo, bool pageValid, bool threadActive) { if ((buttonRPAReset == null)) { return; } } public void ExecuteJob(EdiabasNet ediabas, ref MultiMap resultDict, bool firstCall) { List> resultSets; // hier werden die job results zwischengespeichert // unterhalb der/die JOB(s) zur Datenanzeige ediabas.ArgString = string.Empty; ediabas.ArgBinaryStd = null; ediabas.ResultsRequests = string.Empty; ediabas.ExecuteJob("STATUS_LESEN_RPA"); resultSets = ediabas.ResultSets; if (resultSets != null && resultSets.Count >= 2) { // results der aktuellen Abfrage mit unveränderten result namen übernehmen EdiabasThread.MergeResultDictionarys(ref resultDict, resultSets[1]); } // ENDE JOBs // Button JOB - wenn der RPA RESET button kürzlich betätigt wurde wird dieser code block ausgeführt if (doRPAReset) { ediabas.ArgString = string.Empty; ediabas.ArgBinaryStd = null; ediabas.ResultsRequests = "JOB_STATUS"; ediabas.ExecuteJob("RPA_RESET"); // JOB RESULT ermitteln (wird derzeit nicht weiter verwendet weil man es anhand der geänderten Daten // und den blinkenden LEDs im KOMBI eh sofort sieht) //resultSets = ediabas.ResultSets; //if (resultSets != null && resultSets.Count >= 2) //{ // EdiabasThread.MergeResultDictionarys(ref resultDict, resultSets[1]); //} // Ablaufvariable wieder zurücksetzen, sonst würde dieser Befehl nun bei jedem weiteren Durchlauf ausgeführt werden... doRPAReset = false; } } } ]]>