abhishek415's Profile
Reputation: 0
Apprentice
- Group:
- Active Members
- Active Posts:
- 57 (0.16 per day)
- Joined:
- 30-June 12
- Profile Views:
- 1,755
- Last Active:
Feb 21 2013 05:55 AM- Currently:
- Offline
Previous Fields
- Country:
- IN
- OS Preference:
- Windows
- Favorite Browser:
- Mozilla
- Favorite Processor:
- Intel
- Favorite Gaming Platform:
- Who Cares
- Your Car:
- Who Cares
- Dream Kudos:
- 0
Latest Visitors
-
aresh 
24 Oct 2012 - 07:07 -
modi123_1 
29 Sep 2012 - 10:45 -
nK0de 
22 Jul 2012 - 11:32 -
GunnerInc 
19 Jul 2012 - 14:37 -
macosxnerd101 
19 Jul 2012 - 09:51 -
tlhIn`toq 
19 Jul 2012 - 06:52 -
sela007 
19 Jul 2012 - 00:26 -
varsha0802 
02 Jul 2012 - 06:39 -
H3R3T1C 
01 Jul 2012 - 18:56
Posts I've Made
-
In Topic: Problem in updating the ms access database
Posted 15 Oct 2012
No Sir, I didnot get any error message in message box.
If i had got such error message, then it would have been corrected by me. -
In Topic: Problem in updating the ms access database
Posted 15 Oct 2012
Catch ex As Exception
MsgBox(ex.ToString)
End Try -
In Topic: Problem in updating the ms access database
Posted 15 Oct 2012
I have putted this code in the button_click event.
and i have also applies try catch statement too. but that i did not copied here.
But still the error was not shown. :-( -
In Topic: Problem in updating the ms access database
Posted 15 Oct 2012
Thanks Again Charlie.
I made a very stupid mistake.
The problem was with the order of parameters as said by you earlier. -
In Topic: Problem in updating the ms access database
Posted 15 Oct 2012
now i have put my connection string into the condition.
but now also the same problem is occuring.
There is no error , program terminates after successful completion but database is not updated.My new code is:
Dim dbPath As String = "D:\WindowsApplication1\Medical.mdb" con.Close() con.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;" _ & "Data Source=" & dbPath & ";Jet OLEDB:Database Password=guptaji;" Dim bal As Integer = Val(Me.TextBox2.Text) - Val(Me.TextBox7.Text) MsgBox(bal) str = ("UPDATE Add1 SET [Quantity]=@Quantity where [PName] =@PName") Dim acscmdup1 As New OleDb.OleDbCommand() acscmdup1.CommandText = str If (con.State = ConnectionState.Closed) Then con.Open() End If acscmdup1.Connection = con With acscmdup1 .Parameters.AddWithValue("@PName", Me.ComboBox3.Text) .Parameters.AddWithValue("@Quantity", bal) .ExecuteNonQuery() 'Execute command End With acscmdup1.Dispose() MessageBox.Show("Database Updated", "Updated..", MessageBoxButtons.OK, MessageBoxIcon.Information) con.Close()
Help
My Information
- Member Title:
- D.I.C Head
- Age:
- 23 years old
- Birthday:
- November 7, 1989
- Gender:
-
- Location:
- Gurgaon
- Full Name:
- Abhishek Gupta
- Years Programming:
- 5
- Programming Languages:
- C,C++,Java,VB.Net,VB 6.0
Contact Information
- E-mail:
- Private
- Facebook:
- http://www.facebook.com/#!/abhishekgupta007
|
|


Find Topics
Find Posts
View Reputation Given
|
Comments
varsha0802
02 Jul 2012 - 06:39