Student Information App

Post on 10-Feb-2016

7 views 0 download

description

This program able to displays list of students in Datagridview. The system allows the user to search by last name, first name and course.

Transcript of Student Information App

This program able to displays list of students in Datagridview. The system

allows the user to search by last name, first name and course.

Step 1. Open the Visual Studio 2012 or C# Application

Step 2. click new Project

Step 3. Select Visual C# and then select Windows Forms Application then click ok

Edit the name of your project here

Step 4.Create a form like this, drag the listbox, button and datagridview to the form.

ListBox1

button1

Datagridview1

Select listbox1 and then right click or go to propertiesAnd edit the collection into First Year, Second Year, Third YearAnd Fourth Year just like above.

SecondEdit here

Click thisfirst

Step 5.Select the name of your project here, then select Add after that click Class.

Select Visual C# Items then select Class andName the class as “DBConnect.cs” after that click Add button below.

Click browse then go to C:\Program Files (x86)\MySQL\Connector NET 6.7.4\Assemblies\v4.5If v4.5 didn't work choose v2.0 or v4.0 versionAfter that select the MySql.Data.dllAnd MySql.Data.Entity.dll

Step 6. Select Reference in solution Explorer and then select Add reference

Then go to the folder you download including this Power point and select the “student_students.sql” file then ok and Click button “Start Import”

Click This

Step 7. Go to Desktop and Open the MySQL Workbench application if you don’t have then try to install the installer inside the folder of “Automatic load database ” Then use password: admin when the installation is near to complete, after that open the MySQL Workbench application then click or open the “Local instance” then type the password: admin after that, go to management, Then select “Data Import/Restore” follow the Instruction below.

Select This

Click This

Step 8. Here’s the coding portion, go back to the Visual Studio 2012 Application and go to DBConnect.cs and insert this code.

Insert this code

Start coding here

Continue coding here

Continue coding here

Step 9. Go to your form1 or design double click the form and insert this code.

Insert this

Start coding here

Continue coding here

Continue coding here

Step 10. F5 to run the program and the output is look like this. Select an item from listBox to search

References