Click here to Skip to main content
16,014,882 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i have use this method for display data from one table into textbox,but i don't know how to display data from more then one table into textbox.


C#
ddlcity.SelectedIndex =Convert.ToInt16( dv.Table.Rows[0]["city_id"]);
   txtmob.Text = dv.Table.Rows[0]["mob_no"].ToString();
   txtemail.Text = dv.Table.Rows[0]["emailid"].ToString();
   txtuname.Text = dv.Table.Rows[0]["username"].ToString();
   txtpassword.Text = dv.Table.Rows[0]["password"].ToString();
Posted
Updated 19-Dec-12 23:24pm
v2

write
In dataset multiple tables we can fill.

C#
txtmob.Text=dv.Tables[0].Rows[0]["mob_no"].ToString()+dv.Tables[1].Rows[0]["mob_no"].ToString()
 
Share this answer
 
v2
Try this

C#
txtmob.Text = dv.Table.Rows[0]["mob_no"].ToString()+dv1.Table.Rows[0]"mob_no"].ToString()
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900