private void btnRetrieve_Click(object sender, EventArgs e) { ItemHolder holder = (ItemHolder)drpResults.SelectedItem; if (holder == null) { return; } if (helper.LoadItem(holder.item, context)) { int row = 0; foreach (string fieldname in context.OutputFields) { object val = context[fieldname]; if (val != null) { tblOutputContext.Controls[(row * 2) + 1].Text = val.ToString(); } else { tblOutputContext.Controls[(row * 2) + 1].Text = ""; } row++; } } }
private void AppHelperItemSelected(IAppHelper helper, AppHelperItem item) { System.Diagnostics.Debug.WriteLine(string.Format("got selected item. name: {0}. value: {1}", item.Name, item.Value)); AppHelperContext context = new SimpleAppHelperContext(); if (helper.LoadItem(item, context)) { // if (context["title"] != null) // this.txtMovieName.Text = (string)context["title"]; MediaItem.ReadFrom(context); UpdateDisplay(); } }