构造函数connectionstring vb.net

时间:2016-10-02 09:11:16

标签: vb.net

#Region "Constructors"


Public Sub New()
    MyBase.New("mydatabase.sdf")
End Sub

Public Sub New(ByVal connectionString As String)
    MyBase.New(connectionString, New AttributeMappingSource())
End Sub

Public Sub New(ByVal connectionString As String, ByVal mappingSource As MappingSource)
    MyBase.New(connectionString, mappingSource)
End Sub

在MyBase.New(“mydatabase.sdf”)中如何更改为MySql数据库或Sql Server。我试图把连接字符串但它的错误

1 个答案:

答案 0 :(得分:0)

在我的解决方案myproblem

中的数据库中插入一些数据