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
asghar rahmati
NA
6
0
HOw to show one row for each student in join table in datagr
Oct 13 2013 9:05 AM
Hi
I write this stored prosedure for joined table in my database
create proc joinstudentPayeClassDarsMountGrade1
@TID int
as
select TblStudent.IDSt,TblStudent.FName,TblStudent.LName,
TblStudent.FatherName,TblStudent.BirthDay,TblStude nt.Pic,
TblStudent.IDPaye,TblStudent.CLID,
CLassName,PayeName,TName,TblGrade.TID,Nomre,TblDar s.DID,DName
from TblStudent
INNER JOIN TblGrade ON TblStudent.IDSt=TblGrade.IDSt
INNER JOIN TblClassName ON TblStudent.CLID=TblClassName.CLID
INNER JOIN TblPaye ON TblStudent.IDPaye=TblPaye.IdPaye
INNER JOIN TblMount ON TblMount.TID=TblGrade.TID
INNER JOIN TblDars ON TblGrade.DID=TblDars.DID
where TblGrade.TID = @TID
and bind datagridview with this code
SqlDataAdapter da = new SqlDataAdapter("joinstudentPayeClassDarsMountGrade ", con);
da.SelectCommand.CommandType = CommandType.StoredProcedure;
da.SelectCommand.Parameters.AddWithValue("@TID", CmbTerm.SelectedValue);
DataTable Karname = new DataTable();
da.Fill(Karname);
dataGridView1.DataSource = Karname;
but in datagridview display like this picture
my question :
How to display Name, Last Name ,... for each student in one row with datagridview
Attachment:
grid1.rar
Reply
Answers (
0
)
this Code Can Error Given What proplem given in this code
How to set first next previous last in listview?