•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Visual Basic 4 / 5 / 6 section within the Software Development category of DaniWeb, a massive community of 391,666 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,878 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Visual Basic 4 / 5 / 6 advertiser:
Views: 996 | Replies: 4
![]() |
•
•
Join Date: Jun 2007
Location: india /bangalore
Posts: 18
Reputation:
Rep Power: 2
Solved Threads: 0
hi
i aam trying to develop a project using vb and access
i have got a problem
i have 3 tables in access
1.Cust info table(fields are listed below)
cust id,name,age,sex,country...etcxc(primary key cust id)
2,indate(fields are listed below)
custid ,packageid,date,intime,outime(no primary key)
3.package info table(fields are listed below
package id, package name,duration ,price(primary key packageid)
tthese three tables are connected...the attachment shows how it is connected
i want to write a query to select custid, custname,packageid,packagename,duration,price,date,timein,timeout from these tables in vb..n in a data grid to display these.i know to write simple queries but this one i think it needs inner join n stuff..can any expert resolve my problem..
i aam trying to develop a project using vb and access
i have got a problem
i have 3 tables in access
1.Cust info table(fields are listed below)
cust id,name,age,sex,country...etcxc(primary key cust id)
2,indate(fields are listed below)
custid ,packageid,date,intime,outime(no primary key)
3.package info table(fields are listed below
package id, package name,duration ,price(primary key packageid)
tthese three tables are connected...the attachment shows how it is connected
i want to write a query to select custid, custname,packageid,packagename,duration,price,date,timein,timeout from these tables in vb..n in a data grid to display these.i know to write simple queries but this one i think it needs inner join n stuff..can any expert resolve my problem..
post your code, its more easy to understand
Never tried = Never Know
So, Please do something before post your thread.
* PM Asking will be ignored *
So, Please do something before post your thread.
* PM Asking will be ignored *
•
•
Join Date: Jul 2008
Posts: 2
Reputation:
Rep Power: 0
Solved Threads: 0
like in the following code what i am doing is if i push a button then it should choose next row from stud table and the scho should get the name from text1.text field and match in this table and should display the corrosponding row in scho table
Dim connect_string As String = _
"Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=""" & TextBox4.Text & """;" & _
"Persist Security Info=False"
Dim conn_test As New OleDb.OleDbConnection(connect_string)
conn_test.Open()
Dim cmd4 As New OleDbCommand("SELECT * FROM Stud ORDER BY Name", conn_test)
Dim studAdap As New OleDbDataAdapter
studAdap = New OleDbDataAdapter
studAdap.SelectCommand = cmd4
Dim studTab As DataTable
studTab = New DataTable()
studAdap.Fill(studTab)
'' MaskedTextBox1.DataBindings.Add("text", studTab, "name")
TextBox1.DataBindings.Add("Text", studTab, "name")
TextBox2.DataBindings.Add("Text", studTab, "lname")
TextBox3.DataBindings.Add("Text", studTab, "score")
lblPhotoFile.DataBindings.Add("Text", studTab, "foto")
studMgr = DirectCast(Me.BindingContext(studTab), CurrencyManager)
Call ShowPhoto()
Dim cmd5 As New OleDbCommand("SELECT * FROM scho WHERE scho.name = '" & TextBox1.Text & "'", conn_test)
Dim schoAdapa As New OleDbDataAdapter '*****
schoAdapa = New OleDbDataAdapter
schoAdapa.SelectCommand = cmd5
Dim schoTaba As DataTable '******
schoTaba = New DataTable()
schoAdapa.Fill(schoTaba)
TextBox5.DataBindings.Add("Text", schoTaba, "school")
TextBox6.DataBindings.Add("Text", schoTaba, "city")
Label4.DataBindings.Add("Text", studTab, "foto")
Call ShowFhoto() Last edited by Tekmaven : Jul 15th, 2008 at 11:39 am. Reason: Code tags
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
•
•
•
•
DaniWeb Visual Basic 4 / 5 / 6 Marketplace
- Report w/Cateories/subcategories (PHP)
- Need Help Creating a Search Page (ColdFusion)
Other Threads in the Visual Basic 4 / 5 / 6 Forum
- Previous Thread: fetching data from HTML code
- Next Thread: Help! Database system on LAN



Linear Mode