devxlogo

Tip Bank

Print the WebBrowser’s contents

The WebBrowser control doesn’t expose any method to directly print its contents. You can achieve this effect through the ExecWB method, by passing the OLECMDID_PRINT constant in its first argument:

Programmatically register an ActiveX control or DLL

All ActiveX DLL or OCX export two functions: DllRegisterServer and DllUnregisterServer. They are used to register and unregister the ActiveX in the Windows registry, and are usually invoked from regsvr32.exe

Pushing an Applet from a Servlet

When trying to use an applet inside a servlet using the applet tag: out.println(“” + “”) Two things must be kept in mind: 1.You must include the codebase in the

Treat enum Types as Ordinary Types

You can use an enum type as you would use any other type: You can create arrays thereof, allocated it dynamically using operator new, define pointers to it and return

Understanding Member Function Lookup Rules

Function lookup stops at a scope. In the case of class hierarchies, this means that a function?either virtual or not?declared in a derived class can hide a virtual member function

Avoid Obsolete Win16 Memory Functions

The 16-bit operating systems Windows 3.1x and DOS had a very intricate memory model that required the use of functions like GlobalAlloc() and GlobalLock(). These functions addressed a specific problem