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
noor sherpao
NA
7
618
Help me HOW TO DISPLAY MS ACCESS DATABASE TO C#.NET
Feb 14 2018 8:38 AM
private void AcNotextBox_TextChanged(object sender, EventArgs e)
{
string connString = ConfigurationManager.ConnectionStrings["dbx"].ConnectionString;
string cmdString = "SELECT * FROM tblBasicInfo WHERE ID =" + int.Parse(AcNotextBox.Text);
using (OleDbConnection conn = new OleDbConnection(connString))
{
using (OleDbCommand cmd = new OleDbCommand(cmdString, conn))
{
conn.Open();
OleDbDataReader reader = cmd.ExecuteReader();
if (reader.Read())
{
NametextBox.Text = (reader["SName"].ToString());
FNametextBox.Text = (reader["FName"].ToString());
AddresstextBox.Text = (reader["Address"].ToString());
CelltextBox.Text = (reader["Cell"].ToString());
NationalitytextBox.Text = (reader["Nationality"].ToString());
ReligiontextBox.Text = (reader["Religion"].ToString());
FCNICNotextBox.Text = (reader["FCNICNo"].ToString());
FatherOccuptextBox.Text = (reader["FOccup"].ToString());
TransportFacilitytextBox.Text = (reader["TranFacility"].ToString());
InFiguredateTimePicker.Text = (reader["DOB"].ToString());
DateofAdmdateTimePicker.Text = (reader["DateofAdm"].ToString());
RegistrationNotextBox.Text = (reader["RegNo"].ToString());
TranFeetextBox.Text = (reader["TransportChr"].ToString());
SRemarkstextBox.Text = (reader["SpecialRemarks"].ToString());
ClassofcomboBox.Text = (reader["ClassofAdm"].ToString());
ClassOfReadcomboBox.Text = (reader["ClassofReading"].ToString());
}
}
/forums/uploadfile/d23c61/02142018083523AM/
Reply
Answers (
1
)
Is Wpf is replcae Window Form Developer for desktop
i want insert all from data grid view to data base (entity)