Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Comment out blocks of code.
Message
From
10/02/2005 21:59:51
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 7 SP1
OS:
Windows 2000 SP4
Network:
Windows NT
Database:
Visual FoxPro
Miscellaneous
Thread ID:
00985855
Message ID:
00985860
Views:
30
>I know I can comment out single lines of code by putting an asterisk at the beginning of the line. Is there a way to comment out entire blocks of code as you can in C++ ? I looked at the VFP Help. All it talks about is using the asterisks, NOTE, and double apmersand signs for single lines.
>
>I sometimes want to quickly disable 10 or 20 lines of code.
>
>Thank You.

Another option is the use of IF, or, better, #IF:


#IF .F.
This code
will not be executed
#ENDIF

However, since syntax highlighting only works on a per-line-basis, the code won't appear in the color of comments (green by default).
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform