ToolBox ForeColor "TYPE MISMATCH" Using COL% Instead of COL& (45174)






This article was previously published under Q45174

SUMMARY

The following is a correction for Page 512 of the "Microsoft QuickBASIC for the Apple Macintosh: Users Guide." Under the ToolBox routine ForeColor, the example given will produce a "TYPE MISMATCH" error because COL% (a short integer) is the wrong type. It should be COL&, a long-integer variable.

MORE INFORMATION

The following is a complete, corrected example to invoke the ForeColor ToolBox trap:
   ToolBox "I"
   TrapNo% = &HA862
   col& = 341
   ToolBox "P", TrapNo%, (col&)
   PRINT "This text should be green."
				

Modification Type: Minor Last Reviewed: 1/9/2003
Keywords: KB45174