<include> lines disappear from code

B

Bil Click

I am coding classic ASP pages in Visual Studio .Net 2003.
I have a file called counties_option.asp that just has a
list of options:
<OPTION VALUE="030">ANSON</OPTION>
<OPTION VALUE="040">ASHE</OPTION>
etc...

I then call this as an include file in several places in
a file called page1.asp like this:

<SELECT id="Select7" name="aCounty1">
<OPTION value="All" selected>All</OPTION>
<!-- #include file= '../common/counties_option.asp'-->
</SELECT>

This works OK the 1st few times, I can see all the
options in the drop down list, but after a while (I
have not determined the exact time period or cause) the
<include> lines disappear from the code! (Yes, Mother, I
DID save the file)

I have other include files in this page that are stable -
only the includes in the <select> statements disappear.

Strange!
 
A

Aaron Bertrand - MVP

Tools / Options / Text Editor / HTML/XML / Format
Disable the automatic formatting options ... these are probably to blame, if
the symptom appears after saving the file (or if you switch back and forth
from Design to HTML). If it's the latter, I strongly recommend just using
VS to code, and preview what it looks like in a browser.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,731
Messages
2,569,432
Members
44,832
Latest member
GlennSmall

Latest Threads

Top