devxlogo

Tip Bank

Setting Timeout for ADO

If you have a data driven Web site, you might provide functionality so that a user can delete records from the database via a Web page. If there are lots

How to Construct Images in Memory

There are many simple images (stripes, hue gradients, fractals, and the like) that can easily be constructed in memory via code. To do so, you need a one-dimensional array to

Exploit Serialization To Perform Deep Copy

The clone() method of java.lang.Object class makes a shallow copy of anobject i.e. a copy that excludes the objects that the to-be-cloned object contains. Therefore, to produce a deep copy

The Fraction Gotcha In Java

In Java The expression x/y (x and y are both integers) will represent an integer operation that would result in an integer. So, the result of 4/5 would be 0.

Discover the IP Address of Your Local Machine

The class java.net.InetAddress represents an Internet Protocol (IP) address. It has a static method, getLocalHost(), that you can use to obtain an instance of java.net.InetAddress based on your local machine’s

Why don’t destructors work on global classes?

Question: Why don’t destructors work on global classes? Answer: Actually, destructors do work in global objects. The problem is, they are invoked after the program has ended so you don’t

Overloaded Log File

Question: Our Web server (NT 4.0) became inoperable over the weekend due to a SQL Server error that stated that the “applications log file is full”. From what I understand,