October 29, 1998

Cancel a Pending Print Job

In the tip, “Please Stop Printing!” [“101 Tech Tips for VB Developers,” Supplement to the August 1997 issue of VBPJ, page 13], the code works fine with one exception. If

C/C++ Linking

Question: If I make a C++ library and supply it to a clientwho does not have a C++ compiler, can theycall my C++ functions from their C routines?That is, is

int and class defination

Question: Why is int 2 bytes with real mode compilers, but 4 bytes with protected mode compilers? And why is the class defination ended with ;-mark, since other definations aren’t?

Windows sound programming.

Question: When writing a Windows 95 program using VC++, how do you play a MIDI sound file? Answer: Musical Instrument Digital Interface (MIDI) is a standard used by electronic keyboards

Terminate and Stay Resident Programs

Question: Can you supply me with boilerplate code for a simple console tsr program? I’m using VC++ 4.0, and I want to create a console program to check a directory

Static initialization and free store

Question: Is it valid to attempt to allocate (via ‘new()’) dynamic memory prior to ‘main()’? I am working on software that has static *’s to class objects, and through some