How to Add/Update/Delete Record using MS Access Database
The primary purpose of this code is to teach beginner programmer to familiarize the concept of database programming.
This is particularly for beginner but may also applicable for intermediate programmer.
Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. After downloading it, you will need a program like Winzip to decompress it.
Virus note: All files are scanned once-a-day by SourceCodester.com for viruses, but new viruses come out every day, so no prevention program can catch 100% of them.
FOR YOUR OWN SAFETY, PLEASE:
1. Re-scan downloaded files using your personal virus checker before using it.
2. NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.
Comments
Anonymous (not verified)
Wed, 07/22/2009 - 17:37
Permalink
hi, How to insert a data
hi,
How to insert a data into two table by using acces database with vb.net
Thanx,
Regards,
Sandeep
admin
Thu, 07/23/2009 - 11:40
Permalink
Kindly study Database
Kindly study Database Programming Made Easy.
I already discuss everything in there.
Anonymous (not verified)
Tue, 07/21/2009 - 19:26
Permalink
retrive image!!!
Hi,
Follwing is the coding of save and retrive the image from ms access database in vb.net2008.but its through input box.I just want that user click on a account no.from combobox and image is displayed.
Plz anybody help me.its urgent.
Thanx,
Regards,
Sandeep
admin
Wed, 07/22/2009 - 16:03
Permalink
Use the following code.
Use the following code.
But I'm still wondering why you ask this. Because it is very easy. With your code above it seems that you know this already.
keopoveskl1
Thu, 07/09/2009 - 14:16
Permalink
Hello Joomar
Hello, Could you tell me how to be strong in vb.net.I started in vb.net from beginner,but I don't where should i begin.
Anyway Could you tell me which book should i take a look for the first time? or any website ?
Thank
admin
Thu, 07/09/2009 - 15:31
Permalink
re: Hello Joomar
If you want to become a professional vb.net programmer I suggest you take a look at the Books section above.
You may also wish to study "Database Programming Made Easy".
keopoveskl1
Fri, 07/10/2009 - 11:26
Permalink
Hello Jomar
Anyway,would you like tell me where should i pick up that book"Database Programming Make Easy"? I really interesting with your programming code.On the other hand How long did you study with it? where could i finding that course?
Thank you for helping me!
admin
Fri, 07/10/2009 - 12:49
Permalink
I suggest you take a loot at
I suggest you take a loot at this book Beginning VB 2008 Databases: From Novice to Professional.
Since I'm not new to VB I leart VB.NET almost a month after studying its concept.
Anonymous (not verified)
Thu, 07/02/2009 - 20:16
Permalink
vb2008(list view)
hi,
Thanx for the replied.I want to ask that how the data is view through the list view.I mean like customer id shown in list view and when user click on the id,it shows the full detail of that customer in different fields that fields like cus id,name ,add.i saw ur list view project.but in this fields are also shown from database.i just want to show only data from database and not the fields name.thats field name,i put throgh the components like textboxes.labels and button.will u plz tell how its done,when user clicked on cust id in list view and records would be shown of that customer.
Thanx,
Regards,
Sandeep
admin
Fri, 07/03/2009 - 11:17
Permalink
re: vb2008(list view)
There's a lot of sample of this in almost of my code. Download it and study how it works.
Anonymous (not verified)
Wed, 07/01/2009 - 20:42
Permalink
vb2008
hi,
your source code is very userful as im making a project in vb.net2008 with access database.its really very appriciated.will u plz upload the coding of granting the permisiion of different user for accessing the software or data or it send on my id '[email protected]'
Thanx,
Regards,
Sandeep
admin
Thu, 07/02/2009 - 16:59
Permalink
re: vb2008
Please use the code in hotel reservation system. It has a user permission.
Anonymous (not verified)
Wed, 06/24/2009 - 03:11
Permalink
vb 2008
Hi! It's been a while since I coded something and that was VB6 then. Do you have time to share some codes/programs using VB2008 as I am using it now. I just need to refresh my knowledge. thank you. My email: yan(at)yanspeaks(dot)com
Thank you kabayan!
admin
Wed, 06/24/2009 - 10:35
Permalink
re: vb 2008
Hi kababayan,
Yes you can download the hotel reservation system, enrollment system and you can also study some of my tutorials about .net.
jhervy14
Fri, 05/08/2009 - 10:29
Permalink
THANK for this code, , ,,
Thank for this code it help us, , ,
and i was edited this program, , to improve it.
Thanks you very much, , ,
JHERVY
Anonymous (not verified)
Wed, 03/25/2009 - 07:34
Permalink
thankyou for the code
thankyou for the code
Anonymous (not verified)
Thu, 03/12/2009 - 09:39
Permalink
vb.net Version
I have been coding for several years and now using vb.net 2008. When I try to run your code I get an error on Object reference not set to an instance of an object,
newRow = dt.NewRow() Line 98 I set dt = new datatable because 99% of the time when I see this error it is because the the instance was not created as a new instance. Any Ideas? What version did you code this in ? Thanks Dwain
admin
Thu, 03/12/2009 - 10:24
Permalink
re: vb.net Version
I'm using vb.net 2008, too. I tested it several times without error.
Anonymous (not verified)
Tue, 03/10/2009 - 23:48
Permalink
find record from database
do you have simple code in finding record in the database?
admin
Wed, 03/11/2009 - 09:56
Permalink
re: find record from database
That's pretty simple. Just add a textbox and modify the SQL string. If you still don't know how to do this then reply to this msg and I will create one for you if I have time.
smiley
Fri, 04/26/2013 - 18:21
Permalink
gud day sir!!
can you give us any idea how to use query using vb.net and access?? thank you sir..
Anonymous (not verified)
Mon, 10/05/2009 - 23:57
Permalink
finding a record
please post the coding.....for finding a record using datagrid or textbox....
admin
Tue, 10/06/2009 - 07:59
Permalink
re: finding a record
Browse Visual Basic .NET section. I have already done this.
nova mae genilla (not verified)
Sun, 03/18/2012 - 19:32
Permalink
microsoft visual studio 2005-code for add,delete,edit and save
Hi sir, i just view the video about how to add,edit,save,delete,and search..
can you teach me sir what are the codes for that buttons
because i really want to know sir on what are the codes for those buttons sir for my studies.
I'm just a second year college student willing to know about visual basic studio 2005.
Pls. answer me sir or pls help me sir..
Thank you
Sir, i will be waiting for your respond.. just send it to me sir in my e-mail
[email protected]
Anonymous (not verified)
Tue, 03/10/2009 - 20:52
Permalink
hi gud pm., can i ask? how
hi gud pm., can i ask? how can i run the program that ive download already?? i need ur reply now., thank you..
admin
Wed, 03/11/2009 - 09:54
Permalink
re: hi gud pm., can i ask? how
Don't be too rush when asking question. You need to be polite sometimes to be answered.
You need vb.net to run this source code.
Anonymous (not verified)
Tue, 03/10/2009 - 19:21
Permalink
vb6
can u make same program in vb6?
admin
Wed, 03/11/2009 - 09:52
Permalink
re: vb6
Search for multi column combobox above. The concept is the same with this program.
Anonymous (not verified)
Sun, 10/16/2011 - 00:52
Permalink
SIR
If TextBox1.Text <> "" And TextBox2.Text <> "" And TextBox3.Text <> "" And TextBox4.Text <> "" And TextBox5.Text <> "" Then
con.Open()
Dim up As String = "Update guadalupe set [email protected],[email protected],[email protected],[email protected],[email protected]"
Dim cmd As New OleDbCommand(up, con)
cmd.Parameters.Add(New OleDbParameter("@DR", OleDbType.VarChar, 15)).Value = TextBox1.Text
'cmd.Parameters.Add(New OleDbParameter("@DR", OleDbType.VarChar, 15)).Value = TextBox1.Text
cmd.Parameters.Add(New OleDbParameter("@address", OleDbType.VarChar, 15)).Value = TextBox2.Text
cmd.Parameters.Add(New OleDbParameter("@description", OleDbType.VarChar, 15)).Value = TextBox3.Text
cmd.Parameters.Add(New OleDbParameter("@price", OleDbType.VarChar, 15)).Value = TextBox4.Text
cmd.Parameters.Add(New OleDbParameter("@petsa", OleDbType.VarChar, 15)).Value = TextBox5.Text
cmd.ExecuteNonQuery()
con.Close()
MsgBox("Successfully updated")
Else
MsgBox("Please complete the form")
End If
MY CODE IN UPDATING IT WORKS BUT THE PROBLEM IS ALL ROWS WERE UPDATED AND CHANGES EVERYTHING.. PLEASE I NEED SOME ADVICE
ayush (not verified)
Sat, 05/19/2012 - 15:23
Permalink
i read ur code ...and there
i read ur code ...and there is a problem that
there is needed a 'where ' clause to update a specific row , that's why ur code updating all rows.
ex: Update table1 set name='xyz' where id='123'
Pages
Add new comment