Hi ramco1917,
You need to set the image style attribute width=160px and height=200px.
Please refer below sample.
HTML
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css" />
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.2/js/bootstrap.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" />
<asp:Repeater ID="rptCustomers" runat="server">
<ItemTemplate>
<div class="row">
<div class="col-lg-4">
<div class="form-group">
<asp:Label ID="lblCustomerID" runat="server" Text="ID"></asp:Label>
<asp:TextBox ID="txtCustomerId" Text='<%#Eval ("FileId") %>' placeholder="CustomerId" ReadOnly="true" class="form-control" runat="server"></asp:TextBox>
</div>
</div>
<div class="col-lg-3">
<div class="form-group">
<img src='<%# Eval("Path").ToString().Replace("~","") %>'
alt="image" />
</div>
</div>
<div class="col-lg-4">
<div class="form-group">
<asp:Label ID="lblName" runat="server" Text="Name" ></asp:Label>
<asp:TextBox ID="txtName" Text='<%#Eval ("Name") %>' placeholder="Name" ReadOnly="true" class="form-control" runat="server"></asp:TextBox>
</div>
</div>
</div>
</ItemTemplate>
</asp:Repeater>
Namespace
using System.Data.SqlClient;
Code
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
this.BindImage();
}
}
private void BindImage()
{
string constring = @"Server=.\SQL2019;DataBase=dbFiles;UID=sa;PWD=PASSWORD";
using (SqlConnection con = new SqlConnection(constring))
{
using (SqlCommand cmd = new SqlCommand("SELECT Top 1 Fileid,Name,Path FROM Files", con))
{
con.Open();
rptCustomers.DataSource = cmd.ExecuteReader();
rptCustomers.DataBind();
con.Close();
}
}
}
Screenshot