Codefixer - ASP tutorials, resources and software
ASP.NET 3.5/2.0 Hosting – Click Here
Home   Articles   Resources   ASP directory   ASP Tutorials   Code Snippets   ASP Applications   Forum
Saturday 10 May
MembersPro PayPal - ASP Membership software

DiscountASP.NET – ASP.NET 3.5/2.0 Hosting


ASP Partner ASP Partner ASP Partner more partners...

ASP Comments - Comment Out Code in ASP

Just to point out to those beginners that using an apostrophe at the start of a line or anywhere in a line of ASP code comments out that code. It will not be processed.

The reason I am telling you this is that I spent many's an hour looking at other peoples code thinking what the f*** is that ' for.

Commenting comes in handy because when you come back to look at your code whether 2 weeks or 3 months later, you invariably have difficulty reading and understanding it especially if it is complicated. So if its difficult for you, remember that commenting could also help others who have the misfortune of having to rewrite your code.

<%
'This is a comment, below I will write out my name
response.write "Michael Wall"
%>

Or this

<%
response.write "Michael Wall"    ' This will write out my name Michael Wall
'note that the apostrophe above didn't start on a new line and it doesn't have too
%>

You will also come across fancy ways that people write comments, they all just do the same thing. ie. the apostrophe is all that is needed.

<%
'###### This code Belongs to Michael Wall ##########
'======Script Title HERE=======

%>

LinksPro - Directory  and Link  Management Software




ASP.NET 3.5/2.0 Web Hosting: 3 Months FREE – Click Here!




About | Contact | Advertise | Feedback | Hire Us | Link

Site developed by Michael Wall - Web Design Belfast N.Ireland.
Copyright © 2000-2008. All rights reserved.

Do you intend to move to ASP.NET or have you already?
Yes will do
Have done
ASP does fine
Not a priority


Directory Software