private void dgSearch_BindingContextChanged(object sender, EventArgs e) { if (dgSearch.Rows != null && dgSearch.Rows.Count > 0) { foreach (DataGridViewRow row in dgSearch.Rows) { //Website int websiteNum = (int)row.Cells["WebSite"].Value; row.Cells["WebSiteStr"].Value = WebSiteContext.GetName(websiteNum); //Price double price = (double)row.Cells["Price"].Value; row.Cells["PriceStr"].Value = String.Format("{0:00}", price) + " " + WebSiteContext.GetCurrencyCode(websiteNum); } } }