-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathUserList.aspx.cs
39 lines (35 loc) · 1.15 KB
/
UserList.aspx.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Data.SqlClient ;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
namespace SmartSystems_NS
{
public partial class UserList : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
bindgrid();
}
protected void bindgrid()
{
using (SqlConnection connection = new SqlConnection(ConfigurationManager.ConnectionStrings["Database_ConnectionString"].ConnectionString))
{
SqlDataAdapter adaptor = new SqlDataAdapter("SELECT [Login_id],[FullName],[Emailaddress],[User_type],Deleted, Remarks FROM [Reg_user] ", connection);
DataSet ds = new DataSet();
adaptor.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
connection.Close();
}
}
}
}