A silly tip that may save a few KB's. If you include COMDLG32.INC,
you also get the code for all Common Dialogs baked into your program.
I looked at COMMCTRL.INC and decided to test the same kind of
"$IF NOT %DEF" kind of system on COMDLG32.INC.
By wrapping each Dialog procedure with $IF NOT %DEF() and $ENDIF,
plus using a table like follows, I actually managed to save almost
10KB in a small program that only needed the open/save dialogs. Now
all I have to do, is to remember including this table before the line
that says #INCLUDE "COMDLG32.INC" and uncomment what I want to use.
Example:
'in COMDLG32.INC, wrap individual dialog's code with (adjust accordingly):
etc.. 
------------------
you also get the code for all Common Dialogs baked into your program.
I looked at COMMCTRL.INC and decided to test the same kind of
"$IF NOT %DEF" kind of system on COMDLG32.INC.
By wrapping each Dialog procedure with $IF NOT %DEF() and $ENDIF,
plus using a table like follows, I actually managed to save almost
10KB in a small program that only needed the open/save dialogs. Now
all I have to do, is to remember including this table before the line
that says #INCLUDE "COMDLG32.INC" and uncomment what I want to use.
Example:
Code:
'In program: ' %NOCOLOR = 1 ' %NOFINDREPLACE = 1 ' %NOFONT = 1 ' %NOPRINT = 1 %NOOPENSAVE = 1 #INCLUDE "COMDLG32.INC"
Code:
$IF NOT %DEF(%NOPRINT) ' Printer dialog's code.. $ENDIF $IF NOT %DEF(%NOFONT) ' Font dialog's code.. $ENDIF

------------------
Comment