private void UpdateGridInfo(GridViewRowInfo currentRow) { if (currentRow == null) { return; } this.radGridView1.CloseEditor(); currentRow.Cells["ProductName"].Value = this.radTextBoxProductName.Text; currentRow.Cells["Manufacturer"].Value = this.radTextBoxManufacturer.Text; currentRow.Cells["Lining"].Value = this.radTextBoxMaterial.Text; currentRow.Cells["Dimensions"].Value = this.radTextBoxDimension.Text; if (this.radComboBox1.SelectedIndex != -1) { currentRow.Cells["SalesRepresentative"].Value = this.radComboBox1.SelectedItem.Text; } GridViewNewRowInfo newRowInfo = currentRow as GridViewNewRowInfo; if (newRowInfo != null) { currentRow.InvalidateRow(); } else { ((IEditableObject)this.radGridView1.CurrentRow.DataBoundItem).EndEdit(); } }
private void LoadImage(object state) { GridViewRowInfo rowInfo = (GridViewRowInfo)state; ImageInfo info = (ImageInfo)rowInfo.Tag; string url = info.Url; HttpWebRequest request = (HttpWebRequest)System.Net.HttpWebRequest.Create(url); HttpWebResponse response = (HttpWebResponse)request.GetResponse(); Image image = Image.FromStream(response.GetResponseStream()); response.Close(); info.Image = image; rowInfo.InvalidateRow(); }
private void UpdateGridInfo(GridViewRowInfo currentRow) { if (currentRow == null) { return; } radGridView1.CloseEditor(); UpdateWorkerInDB(currentRow); GridViewNewRowInfo newRowInfo = currentRow as GridViewNewRowInfo; if (newRowInfo != null) { currentRow.InvalidateRow(); } }