473,480 Members | 1,661 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

student info

8 New Member
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'load

Dim objconn As New OleDbConnection("PROVIDER=MICROSOFT.JET.OLEDB.4.0; Data Source=c:\IQRA.mdb")
Dim objda_prog As New OleDbDataAdapter("select distinct program from program", objconn)
Dim objDA_majors As New OleDbDataAdapter("select distinct majors from majors", objconn)
Dim objds_prog As New DataSet
Dim objds_majors As New DataSet
5:
objda_prog.Fill(objds_prog, "program")

objDA_majors.Fill(objds_majors, "majors")


ComboBox1.DataSource = objds_prog.Tables("program")
ComboBox1.DisplayMember = "program"
ComboBox1.ValueMember = "program"

ComboBox2.DataSource = objds_majors.Tables("majors")
ComboBox2.DisplayMember = "majors"
ComboBox2.ValueMember = "majors"


End Sub

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
'add
Dim objconn As New OleDbConnection("PROVIDER=MICROSOFT.JET.OLEDB.4.0; Data Source=c:\IQRA.mdb")
Dim objcmd As New OleDbCommand("INSERT into student (name, program, specialization, shift) values ( '" & TextBox2.Text & "', '" & ComboBox1.SelectedValue & "', '" & ComboBox2.SelectedValue & "', '" & ComboBox3.Text & "')", objconn)
Dim OBJDR As OleDbDataReader

objconn.Open()
objcmd.ExecuteNonQuery()
MsgBox("Record Successfully Added")
objconn.Close()




End Sub
'show all
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Dim Second As New display
Second.Show()

End Sub








Private Sub Display_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'load
OleDbDataAdapter1.Fill(DataSet41)
DataGrid1.DataSource = DataSet41.Tables(0)

Dim objconn As New OleDbConnection("PROVIDER=MICROSOFT.JET.OLEDB.4.0; Data Source=c:\IQRA.mdb")

Dim objda_prog As New OleDbDataAdapter("select distinct program from program", objconn)

Dim objDA_majors As New OleDbDataAdapter("select distinct majors from majors", objconn)

Dim objds_prog As New DataSet

Dim objds_majors As New DataSet

objda_prog.Fill(objds_prog, "program")

objDA_majors.Fill(objds_majors, "majors")


ComboBox1.DataSource = objds_prog.Tables("program")
ComboBox1.DisplayMember = "program"
ComboBox1.ValueMember = "program"

ComboBox2.DataSource = objds_majors.Tables("majors")
ComboBox2.DisplayMember = "majors"
ComboBox2.ValueMember = "majors"

End Sub

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
'show all

Dim obj As New datalayer
DataGrid1.DataSource = obj.BRING_DATA("select * from student where program= '" & ComboBox1.SelectedValue & " ' and specialization= '" & ComboBox2.SelectedValue & "'")


End Sub

Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click

'restore all
Dim obj As New datalayer
DataGrid1.DataSource = obj.BRING_DATA("select * from student")


End Sub

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
'ok
Dim obj As New datalayer
DataGrid1.DataSource = obj.BRING_DATA("select * from student where name like '%" & TextBox1.Text & "%'")

End Sub
Jul 26 '06 #1
0 1581

Sign in to post your reply or Sign up for a free account.

Similar topics

6
1319
by: suenacita1 | last post by:
Hi. I'm a masters student at the George Washington University currently taking an Open Source Software Development course. One of our assignments was to do a presentation on an open source project...
0
4448
by: Janet Carmichael | last post by:
Hello: Is there a sample data model for a college/school to handle course scheduling, student info etc? My partner and I were saddled with this task when one of the consultants pulled out at...
0
1682
by: Attique | last post by:
Anybody Having STUDENT INFO SYSTEM Docomentation please mail me at the given address attique@ciit.net.pk
8
1937
by: Sue | last post by:
Hello! I am back with another question. Remember I am a new JavaScript student and I am aware that this code does not check for all the possibilities and that as a "NEW" JavaScript student I am...
6
2380
by: laj | last post by:
HI, Excuse this new question, I am trying to impress my wife by putting a db together for her dance studio. I put a table with all students new and old with fields including name and address and...
8
3211
by: ChrisMac | last post by:
Greetings, I have a database that keeps track of students grades (and lots of other info)for a non-profit training center. I have created an access database to track all of the student's...
1
3343
by: GS | last post by:
I am looking for some software package for students information for school, is there any open-source package available?. This should collect complete student information like: student details,...
2
9674
by: sallyk07 | last post by:
Modify the Student class so that each student object should also contain the scores for three tests. Provide a constructor that sets all instance values based on parameter values. Overload the...
3
2667
by: Synapse | last post by:
hi everyone..im trying to create a student list program using linked list that will display all my info of students..but it seems theres a little prob. after i enter my first student the program will...
0
7044
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7084
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
6929
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5337
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4779
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
2984
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1300
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
563
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
181
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.