FYI, |DataDirectory| resolves to the App_Data directory for ASP.NET apps and for ClickOnce apps it automatically resolves to the special folder managed by ClickOnce for data files. For other apps, it resolves to the program folder by default but you can change that in code if you like. That allows you to do things like use the common application data folder on every machine while still just using |DataDirectory| in a connection string stored in the config file.