June 20, 2001

Send All Your System Messages To File

Often, while developing a system you want to debug it using System.out.println or System.err.println. When development is over you would like to send all those messages to file. The easiest way to do this is to assign System.out and System.err to corresponding files. Here is the code: public class MyClass{

Creating an Object When its Class Is Unknown Before Runtime

If you are writing an application in which you don’t know the class of an object until runtime, then you cannot use the new operator to instantiate the object. This is because new does not take the name of class file as a parameter. In this situation, you have to

Use Assertions For Detecting Errors

The assert macro can be used to detect errors as soon as they occur. This macro is defined in the include file , and is used that way: assert (expression) ; If expression is false, the program will stop. This indicates which assertion failed.The really nice thing about this macro

The EBCalendar User Control

This User Control is designed to fit the needs of the coder who needs a date entry field without the overhead of having to ship (and install) the Microsoft Windows Common Controls-2 OCX. The control is a self contained User Control which can be added to any project or compiled