TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
jesper
NA
89
54k
SQLDatareader select top from database and show on webform
Feb 6 2013 9:00 AM
I have a connection class with this content:
public class Dal
{
public SqlConnection connection()
{
SqlConnection conn = new SqlConnection(@"Data Source=.\SQLEXPRESS;Database=Manager_db; Integrated Security=true;");
return conn;
}
}
in another class i have the method to select colums from my database:
public SqlDataReader fillrecentchanges()
{
SqlConnection conn = databaseobj.connection();
conn.Open();
SqlCommand cmd = new SqlCommand(@"SELECT TOP 3 FROM Manager_tb", conn);
SqlDataReader rdr = cmd.ExecuteReader();
return rdr;
}
How do i list the 3 first entry in a webform under each other without columnames?
// Jesper
Reply
Answers (
2
)
How to make privilege form for the user.?
How can I resolve xml read and encode problems?