I managed to create a database using Linq-to-SQL with the following code:
private static DataClasses1DataContext _dataDC = new DataClasses1DataContext(@"C:\\database1.mdf");
public AddClient()
{
InitializeComponent();
DataContext = this;
_dataDC.CreateDatabase();
}
and this created a new local database on C: .
How can I change the @"C:\\database1.mdf"
so that the file is created in the current directory from where I run the program ?