User-2057865890 posted
Hi Hrishik,
You can try to use what I mentioned below.
It is just a demo code to give you an example you can also modify it by yourself.
<%@ Page language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>ASP.NET Example</title>
</head>
<body>
<form id="form1" runat="server">
<asp:SqlDataSource
Id="dsCustomer"
runat="server"
DataSourceMode="DataReader"
ConnectionString="<%$ ConnectionStrings:DataAccessStart1%>" SelectCommand="SELECT DISTINCT CustomerCode,CustomerName,CustomerPhone from CustomerMaster where CustomerCode in(114,11,19,232,145,241)">
</asp:SqlDataSource>
<asp:ListBox
id="ListBox1"
runat="server"
DataTextField="LastName"
DataSourceID="SqlDataSource1">
</asp:ListBox>
</form>
</body>
</html>
Regards,
Chris