
Date Arithmetic in Java
Question: I have a ResultSet created using JDBC and it contains some datefields. Now I want to subtract one date from the other. Howdo I do this? Answer: Date arithmetic

Question: I have a ResultSet created using JDBC and it contains some datefields. Now I want to subtract one date from the other. Howdo I do this? Answer: Date arithmetic

Question: How can I force a reload of a JavaBean that is being used in a JSPpage? The problem is I am developing a JSP-based Web application andI need to

Question: I have two tables: Items_table: Item_id (primary key) Description (foreign key) Item_priceDescrip_table: Description (primary key) Item_type How do I enter information into the two Description columns simultaneously? Answer: An

Question: Is it possible to change the name of a column within a table after it has been created? For example, I want to change the column “Name” to “FName”.

Question: When I build my application as an EXE and run it, the application comes up and then immediately disappears. What is wrong? Answer: You need to create an event

Question: How can I fill a numeric field with a sequence of numbers using SQL? For example, I want a field named NUMBER to contain the numbers 1 for the

Question: We have a private WAN network with Exchange Server 5.5 and also have one inbound/outbound Internet mail service for all people to use to send Internet e-mail. I want

Question: I created a command button on the main form. It runs another wizard-generated form that edits a table in the database container. It works in test, but when I

Question: I’m having a problem creating a context menu in a grid (by clicking on the right button of the mouse). I created this menu by programming a method that

Question: How do you open a specific Word document through a Visual FoxPro program? Answer: You simply add the document to the Word.Application’s Documents collection. Here is a code sample

Sometimes is useful to know how many buttons the user’s mouse has. This value can be obtained by calling GetSystemMetrics. The constant to pass as parameter is SM_ CMOUSEBUTTONS. Here’s

Have you ever needed to open a Windows dialog such as Internet Properties, New Hardware, Modem Properties or any other dialog you can find in the Control Panel? Well, it’s

If you need to know how Windows was started you have just to call an API function: GetSystemMetrics. Passing the SM_CLEANBOOT constant as parameter, the function returns a Long value

It takes only a handful of lines of code to create Windows inspector program, that is, an utility that lets you display the handle, the class name and the contents

The dialog you see when you start an Internet connection is implemented in the RNAUI.DLL file, and the specific function is called RnaDial. To open this dialog from your application

As you know, when you press CTRL+ALT+CANC the Task List window appears. This dialog allows you to see all the running processes and also to terminate them. If you don’t

Browsers Targeted: Internet Explorer 4+ Dates can be a pain to deal with when working with scripting. Fortunately VBScript 5.0 supports a number of different functions that can simplify the

Browsers Targeted: Internet Explorer 3+, Netscape Navigator 3+ You can take advantage of the new XHTML standard in your own code, regardless of your browser, to enhance the capabilities of

Question: I would like to force data entered into a form to be uppercase. This is probably basic, but I can’t figure it out! Answer: What you are looking for

ne of the more common questions here at Ask the VB Pro has always been how to automatically handle the resizing of forms and controls. Unfortunately, the short answer is

he previous two 10-Minute Solutions covered a couple of different techniques to present a recordset of data in the form of logical pages so that the user could navigate from

he way that XML is being used, of late, is beginning to send tremors throughout much of the programming world. Part of this has to do with an obvious logical

he Java core packages include jave.util.zip, which is useful forcreating and reading compressed files or archives in the ZIP and GZIPformats. ZIP files form the basis for the JAR file

Data types larger than the size of a byte aren’t portable because of the different endian-ordering of each hardware architecture. This means that passing an int in its binary form

It’s a fact that applications spend 80 percent of their time executing 20 percent of their code. Some even claim that the ratio is higher: 90-10. Usually, programmers can’t assess

Sometimes, legacy code that contains Plain Old Data (POD) types (i.e., dumb structs that don’t have any member functions) can use an object-oriented “face lift”, e.g., adding a constructor or

Several compilers need this hint from the programmer while others are clever enough to figure it out automatically. When you have nested loops, declare the counter of the most deeply-nested

Generally, compilers can’t inline a virtual function call if the it’s resolved dynamically. Therefore, declaring a virtual member function inline might seem pointless. However, not every call of a virtual

Browsers Targeted: Internet Explorer 4+ In Internet Explorer, you can assign images and colors into table cells and table rows through the background-image and background-color CSS attribute within style sheets.

eb developers awake! XHTML (Extensible HyperText Markup Language) is coming to a server near you. It’ll change everything you ever knew about Web design, give you untold power on the