Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

SqlCeConnection::DataSource Property

Gets the file name of the data source.

Namespace:  System.Data.SqlServerCe
Assembly:  System.Data.SqlServerCe (in System.Data.SqlServerCe.dll)

virtual property String^ DataSource {
	String^ get () override;

Property Value

Type: System::String
The location and file name of the data source. The default value is an empty string.

In SQL Server Compact, DataSource is returned as the full path of the database file; for example, "\my app\myDB.sdf". In SQL Server Compact, databases are always stored in separate files.

© 2015 Microsoft