Connection String Overwritten by vs.net

  • Thread starter Thread starter IntraRELY
  • Start date Start date
I

IntraRELY

I constantly am having code over written by vs.net. It is a connection
object and I am referencing the connection string from the web.config. How
do I make vs to stop doing this?

TIA,

Steve
 
Can you step through your code and pinpoint exactly where and under
what conditions this is happening?

--Mary
 
Hi,

Are you talking about code being overwritten by the VSNET Designer in the
Windows Forms Designer Code #region?

If yes, you are not supposed to make any changes in that region. Instead,
set your connection string @ Page_Load or so.

Else, please mention where and how exactly this happens.

HTH,
Rakesh Rajan
 
Yes I have put into the:

#Region " Web Form Designer Generated Code "
....myCode
#End Region

Is there any way to make it stop. I would really like to put it there
because it is where it is stored by default and to keep things familier.

TIA,

Steve
 
Back
Top