private void fullingThingList(AllThingsJson.Rootobject allThings) { foreach (AllThingsJson.Row row in allThings.rows) { thingList.Items.Add(row.name); } thingList.SelectedIndex = 0; }
private async void cicleMethod(AllThingsJson.Rootobject allThings) { Messenger messenger = new Messenger(AuthInfo(), Address(), AuthorizationType()); while (this.cicleRun) { foreach (AllThingsJson.Row row in allThings.rows) { //await cicleGetPropertyAsync(row.name); if (!this.cicleRun) { break; } } await Task.Delay(temp()); } }
private async void sendReqest_Click(object sender, EventArgs e) { if (checkFields()) { string address = Address(); if (authorizationType.SelectedIndex == 0) { log("указанный ключ: " + uuid.Text); } this.allThings = await getThingsAsync(address); if (this.allThings != null) { //CicleRequestStart.Enabled = true; this.thingsPropertyInServer = new Dictionary <string, string> [this.allThings.rows.Length]; fullingThingList(this.allThings); } } }