I have an Access frontend with a SQL Server 2008 backend. The Server has a LiveSales database as well as TestSales database.
I would like to write code in Access that fills a label box on the main form with "TEST DATABASE" if the current database is anything other then "LiveSales". I need help with the code/connection string that I need to use.
If Current database is "LiveSales" then
lblTestDb = "TEST DATABASE"