Exemple #1
0
        private string GetImagePath(long id, ProductTableAdapter productAdapter)
        {
            var imagePath    = "";
            var productTable = new DBProduct.ProductDataTable();

            try
            {
                productAdapter.FillById(productTable, id);
                if (productTable.Rows.Count > 0)
                {
                    imagePath = productTable.Rows[0]["ImagePath"].ToString();
                }
            }
            catch (Exception exception)
            {
                Log.Error(id + exception.ToString());
            }
            return(imagePath);
        }