Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Apr 09, 2012 04:21 AM by aspnet100
Apr 07, 2012 08:18 AM|LINK
Thanks in advance.
I'm using VS 2010 with a Razor project and I'd like to use a transformation to change the DB connection string to a debug version when I'm debugging. I'm not connecting to the production DB in debug mode, I'm using a local copy. I've tried this...
Source=machine;Initial Catalog=DBname;User ID=sa;Password=pass"
When I start debugging, the connection does not change. I've tried Replace instead of SetAttributes, and I also tried deleting the files and using "Add config transformations" to regenerate the file from scratch.
Is this supposed to work in this way, or is this feature meant to only work on publish? If so, what's the best practice for what I want to do?
Apr 09, 2012 04:21 AM|LINK
It works fine if you publish. The "Replace" option will change the values based on whether you publish in Debug or Release mode.