How can you link two sql tables on two diffrnt c# forms? | Sololearn: Learn to code for FREE!
Neuer Kurs! Jeder Programmierer sollte generative KI lernen!
Kostenlose Lektion ausprobieren
0

How can you link two sql tables on two diffrnt c# forms?

trying to connect two slq tables on two dfrnt c# forms so when you click the datagridview on form one and open form two you get the same record information... table one in form one has the record info... table two in form two has the record photos... and the two tables are connected in a relaion

19th Aug 2017, 2:22 AM
Claro Navo
Claro Navo - avatar
1 Antwort
0
It really depends on how the two forms work together. If it has a showdialog structuur. So the second form appears after a row is selected in the datagrid. Then you can keep the data on the datagrid. You assign the image which is hidden in your datagrid to a image property of the second form and the second form does not need to do anything with the database. If both forms are shown at the same time, I do not understand why you have 2 forms. If you want to look for examples search for Master-Detail http://csharphelper.com/blog/2016/02/display-masterdetail-data-in-a-datagrid-in-c/
19th Aug 2017, 9:16 PM
sneeze
sneeze - avatar