I try to write access connection string in SqlBulkCopy but I got error Keyword not supported: 'provider'
here is my code:
bulk = New SqlBulkCopy("Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" & mFileName & ";Jet OLEDB:Database Password=hmis;")
bulk.DestinationTableName = "Advance"
bulk.WriteToServer(dt_table)
SqlBulkCopy only works with SQL Server. The constructor you are trying to call, SqlBulkCopy(string) expects a valid connection string for SQL Server. The connection string you passed works only with Access.
Different databases products have different mechanisms for bulk import operations. You can't use a class created for one database product to import data to another.
Microsoft Access has no bulk import support.
The SQLBulkCopy Class is only supported with SQL Server connection string. You can't use other types of Connection Strings..