| Page 6 Compiling DataFlex Programsby Curtis KrauskopfSummaryMultiple files can be compiled on one 
                          command line by using the FOR 
                          command parameter. The FOR 
                          command can be used on both the command line and inside 
                          of a batch file.  Compile-time error alerts can be suppressed 
                          but recorded in .ERR files 
                          by appending a -v1fskn 
                          parameter to the dfcomp 
                          command line. dfcomp is 
                          somewhat braindead when it comes to compile options. 
                          The following command line will not work:  
                          
                             
                              | Incorrect:dfcomp -v1fskn menu.src
 |  This will try to compile the file -v1fskn 
                          and completely ignore the MENU.SRC 
                          parameter. The correct way to format the above dfcomp 
                          command is:  
                          
                             
                              | Correct:dfcomp menu.src -v1fskn
 |  By making use of the echo, 
                          if, ERRORLEVEL 
                          and shift Windows batch 
                          commands, a fairly intelligent batch file can be created 
                          that allows a programmer to compile multiple groups 
                          of source files using wildcards on one command line. The batch file is even friendly enough 
                          to detect when no parameters were provided, and to automatically 
                          handle the housekeeping of deleting .ERR 
                          files from previous batch compilations. I 
                          hope that you enjoyed this article and learned something 
                          interesting about DataFlex and Windows batch files. 
                          Let me know if you liked it (or not). Your feedback 
                          will help guide me when writing future articles. Curtis 
                          Krauskopf (email at  ) Curtis Krauskopf is a software 
engineer and the president of The Database Managers (www.decompile.com). 
He has been writing code professionally for over 25 years. His prior projects 
include multiple web e-commerce applications, decompilers 
for the DataFlex language, aircraft simulators, an automated Y2K conversion 
program for over 3,000,000 compiled DataFlex programs, and inventory control projects. 
Curtis has spoken at many domestic and international DataFlex developer conferences 
and has been published in FlexLines Online, JavaPro 
Magazine, C/C++ 
Users Journal and C++ Builder Developer's Journal.  
| The Database Managers 
		helps companies to: Email them at become more profitable grow their 
			business fix programs 
			that are behaving badly write new programs 
			to solve business problemsdo more with 
			fewer resources
  to find out how to make your company more successful. |    
                           
                            | Go 
                              Back to Page: 1   2   3   4   5 |  |  Go to DataFlex TipsCopyright 2003-2010 The Database Managers, Inc.   
 Other Popular DataFlex topics at The Database Managers, 
  Inc.: |