Mar 20, 2017 05:08 AM
(This post was last modified: Mar 20, 2017 05:40 AM by adenfr.)
hello there im making a programme that generate sqlserver code to use it in my vb.net progarrme
i have first form conatain the connection like you see in picture below
![[Image: 0OrPt]](https://imgur.com/a/0OrPt)
the connection is works 100%
but in second form i have 2 datagridview
1- for tables
2- for fields
so when i click in any table of data gridview1 => datagridview2 show it fields
but when i clike on datagridview1 to get the value of combobox form form1 to use it in form2 i have error
https://imgur.com/a/TYjMq
Failed to connect to server.
my script
Dim frm As New Form2
prd.ServerConnection = New ServerConnection(frm.ComboServer.Text) ' here the error
prd.DGVField(MetroGridTables, MetroGridField)
so i use form1 to making connection and form2 to make operation but i have
Failed in connection to server.
i have first form conatain the connection like you see in picture below
the connection is works 100%
but in second form i have 2 datagridview
1- for tables
2- for fields
so when i click in any table of data gridview1 => datagridview2 show it fields
but when i clike on datagridview1 to get the value of combobox form form1 to use it in form2 i have error
https://imgur.com/a/TYjMq
Failed to connect to server.
my script
Dim frm As New Form2
prd.ServerConnection = New ServerConnection(frm.ComboServer.Text) ' here the error
prd.DGVField(MetroGridTables, MetroGridField)
so i use form1 to making connection and form2 to make operation but i have
Failed in connection to server.



![[Image: a7CglB3.gif]](https://i.imgur.com/a7CglB3.gif)