Please help me in the following matter:-

vb6 Ado database connection
vb6 Ado recordset connection
show record
add record in database
delete record from database
edit record from database
find record from database
and all sort of ado connection

and add record in datagrid
Please give me solution.

Recommended Answers

All 10 Replies

Well lets see,... Using the first of my friends (yahoo, google, ask, answers, bing) I searched on your first phrase and this are the results...

http://search.yahoo.com/search;_ylt=A0oGki0ppVJLndwA4JRXNyoA?p=vb6+ado+database+connection&fr2=sb-top&fr=yfp-t-701&sao=1

and loooook.... the first one covers most of what you are asking...

http://www.vb6.us/tutorials/database-access-ado-vb6-tutorial

but just to be on the safe side, you had better search with the rest of your phrases but I suggest you make sure you put vb6 infront of the rest of them like you have for the first two...

Good Luck

you can down load free project from search engine. then you can see what u want.

Please help me in the following matter:-

vb6 Ado database connection
vb6 Ado recordset connection
show record
add record in database
delete record from database
edit record from database
find record from database
and all sort of ado connection

and add record in datagrid
Please give me solution.

That simply means you need to read books .

What about using VB 6.0 wizard to create any database application from scratch and check the code that system generates for you.

Please help me in the following matter:-

vb6 Ado database connection
vb6 Ado recordset connection
show record
add record in database
delete record from database
edit record from database
find record from database

Please Help me in the following matter-
ado listview best code
add, delete, edit, search etc.
Thank You with regard

Hi Kalusingh,
Was your problem solved? if not I think I can help you with some source code that i have learned from Other source codes. However explaining all you need is time consuming and all your questions will be answered by reading basic tutorials about MSAccess and VB.

Good Luck
Thanks

Error Handler
Please help me. i have a project but i have a problem in adding record in database.Because 80004005 error is shown plz help me to resolve this problem.i m given you my code....

Private Sub Command1_Click()
On Error GoTo ErrorHandler
Error 424 'This error is displayed when there is a missing object
Exit Sub
ErrorHandler:
MsgBox "Please Choose Another ID ", vbCritical, " ID Already Exist "
If Text1.Text = "" Or Text2.Text = "" Or Combo1.Text = "" Or Text3.Text = "" Then
MsgBox (" Complete The Form ")
Else
Set main.rs = main.cn.Execute("insert into employees (id,employeename,fathername,contractorname)values ('" & Text3.Text & "'" & "," & "'" & Text1.Text & "'" & "," & "'" & Text2.Text & "'" & "," & "'" & Combo1.Text & "'" & ") ")
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
Combo1.Text = ""
End If

'add the following controls first
Command1
Name:cmdADD
Caption: Add Record

Command2
Name: cmdSAVE
Caption: Save Record

Command3
Name: cmdDELETE
Caption: Delete Record

Adodc1
Name: adoUsers
ConnectionString:'u'll find this on propery bar for this control. Click on that property, select provider tab, select ms jet 3.0, or 4(ensure that u've a database named "Users" if not then create it using ms acces or visual data manager.Create a table called "User" and Add FirstName and SecondName as fileds).On RecordSource tab Select table, then tablename "User"
RecordSource: User

Text1
Name: txtFirstname
DataSource: adoUsers
DataFiled: FirstName

Text2
Name: txtSecordName
DataSource: adoUsers
DataFiled: SecondName

Label1
Name: lblFirstname
Captio: Firstname

Label2
Name: lblSecondname
Captio: Secondname

'Coding
Private Sub cmdADD_Click()
On Error GoTo ErrHandler
adoUsers.RecordSet.AddNew'Opens the recordset ready for data
ErrHandler:
If Err Then
MsgBox Err.
End Sub

Private Sub cmdSAVE_Click()
If txtFirstName.Text="" Then
MsgBox"Firstname missing"
txtFirstName.SetFocus
Exit Sub
ElseIf txtSecondname.Text="" Then
MsgBox"Secondname missing"
txtSecondname.SetFocus
Exit Sub
Else
adoUsers.RecordSet.Save'Save data in database
Exit Sub
End If
End Sub

Private Sub cmdDELETE_Click()
If MsgBox("Delete?",VbYesNo)=VbYes Then
adoUsers.RecordSet.Delete
adoUsers.Refresh
Exit Sub
Else
Exit Sub
End If
End Sub
'I hope this will help u

SHAIKHS, Please start your own thread. thins thread is nearly 1 year old.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.