Finally, it is working like a charm. Thanks to you JMC. I have rework my coding and realized i had some issues with the way my bindingsources were filled in from the datasets. Anyway, here is my final code and i dont even use ResetCurrentItem() anymore. I know you were questioning why i needed...
Hi mate,
so I believe I've fix my connection issue and have now the current mdb in my project. When I build the solution in debug mode, I can see the copy of my dbServauto in \bin\Debug\ Folder and so on.
Back to my issue with updating the KM field, I've tried to test the update value like...
ok thank you JMC - I have some reading to do since im obviously very confused with the database connection and links. Ill definitely look into your signature and learn starting right now. Hope ill resolve my problem by then :)
thanks again
ok I've added my .mdb file to the solution explorer and the Copy To Output Directory property is set to : always copy
I rebuild the solution and now I can see dbServuato.mdb file in my \bin\Release folder
oh ok - so here the updated code :
[Private Sub btnUpdateKM_AddF_Click(sender As Object, e As EventArgs) Handles btnUpdateKM_AddF.Click
Using dialogue As New Form2
Dim currentrow = DirectCast(bindingcar.Current, DataRowView)
dialogue.tbKM.Text =...
I got it - bindingcar.resetbindings(false) now works perfectly .
and here is my connection string in my btnUpdateKM code and this code now works perfectly.
Private Sub btnUpdateKM_AddF_Click(sender As Object, e As EventArgs) Handles btnUpdateKM_AddF.Click
Dim Conn As...
Hi ,
so I used your code on my form1 button as follow :
Private Sub btnUpdateKM_AddF_Click(sender As Object, e As EventArgs) Handles btnUpdateKM_AddF.Click
Dim Conn As OleDb.OleDbConnection
Dim Trans As OleDb.OleDbTransaction
Dim Cmd As OleDb.OleDbCommand...
Hi everyone,
I've been trying to fix that issue for some times now and i need your help please.
Basically, i have 2 forms (form1 and form2). I have a set of textboxes on form1 that are bind on a dataset via a bindingsource. when form1 is loaded, all textboxes are filled in correctly. Now i want...
works perfectly as I wanted like this using the CurrentCellDirtyStateChanged event :
Private Sub dgFactures_CurrentCellDirtyStateChanged(sender As Object, e As EventArgs) Handles dgFactures.CurrentCellDirtyStateChanged
Try...
i have rework my code based on your last comment as below :
Private Sub Form2_Load(sender As Object, e As EventArgs) Handles MyBase.Load
con.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|dbServauto.mdb"
con.Open()
sqlP = "SELECT * from...
hi there,
hopefully the title is clear enough - what im trying to achieve is create an invoice form where the user can fill in the cells in the datagridview like Qty, Code, Description and price.
Qty is a textbox - user enter value manually
Code is a combobox - user pick a value from the list...
yes :welcoming: I never tought ill enjoy coding in vb net as im doing right now. Lots of resources available to help switch from vba to vb and experts like you to guide me onto the right path.
I got it work now - thank you jmc - I finally used the generate connection string - I just add the db into my project and use |DataDirectory|. Im working on the app.config and will call my connection from there as you suggested.
thank you
Hi everyone,
I have a button and when clicked, open a panel with 2 combobox on a form. Depending on the selection of the first combobox (which is filled via a bindingsource) , ill be able to select the value I need on the second combobox. and here is my code for that :
Private Sub...
By the way, I read the documentation about connection strings and config file and will definitely going to use that instead of keeping it hardcoded as is - thank you again for those tips - always learning new things from you :)
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.