The Latest

DevX - Software Development Resource

Project-Wide Configuration Management

Configuration management tools (for example, PVCS, Visual SourceSafe) are not just for source code. Use your configuration management tool for storing design documents, prototypes, incremental builds, test scripts, and important

DevX - Software Development Resource

The C++ Keywords

The Standard C++ keywords are: asm auto bool break case catch char class const const_cast continue default delete do double dynamic_cast else enum explicit export extern false float for friend

DevX - Software Development Resource

A Using Declaration and a Using Directive

A namespace is a scope in which declarations and definitions are grouped together. In order to refer to any of these from another scope, a full qualified name is required.

DevX - Software Development Resource

What’s in a “deprecated feature”?

C++ has been around for more than 15 years. During that long period it has been significantly extended, improved, and standardized. One of the consequences of any standardization process is

DevX - Software Development Resource

Built-in types have a constructor

In standard C++ built-in types such as char, int and float can be initialized like any ordinary user-defined type: char *pc = new char(‘a’); int pi= new int(10); float pf

DevX - Software Development Resource

Standard Headers’ Names

All Standard C++ header files must be included in the following way: #include //note: no “.h” extension#include//…other #include statements That is, the “.h” extension should not be used. This technique

DevX - Software Development Resource

Hex system

Question: I am trying to create a program that will log HTML color schemes to a file, and I can’t get C++ to count in hex. I looked in the

DevX - Software Development Resource

Virtual memory on large dataset

Question: I’m working with large multidimensional dataset (> 10 dimensions and > 100,000 points). One particular problem I have is the use of virtual memory (for example, via new). When

DevX - Software Development Resource

Programming in in Win32

Question: I have taken two semesters of C++ and feel pretty confident about the whole OOP aspect of things. I have a good understanding of all the fundamentals of C++.

DevX - Software Development Resource

Macro and functions

Question: What is a macro? What is the difference between macros and functions? How do you invoke a macro? Please give an example of code. Answer: A macro is simply

DevX - Software Development Resource

Compilation Errors

Question: What is an “lvalue”? How does it relate to “rvalue”? Answer: An lvalue is simply a value on the left side of an expression, and an rvalue is a

DevX - Software Development Resource

Stay on Bottom Forms

Question: Is there a way to make a window like the Stay on Top window, but make it stay behind? For example, if you click on the desktop it does

DevX - Software Development Resource

C++

Question: I am thinking of learning C++, and I have not yet looked into it. Why would one choose to code in C++ instead of any other language? What is

DevX - Software Development Resource

VID 1 Environment Mystifying

Question: I have been doing VB since 1.0, and Frontpage since 1.1, however VID’s IDE has me mystified. What book would you recomend. I am at a total loss.Syd Answer:

DevX - Software Development Resource

Text Orientation in a Bitmap

Question: How is it possible to write a vertical text (with TextOut procedure) in a bitmap (Delphi 2)? Answer: I know how to do this with a TLabel descendant, but

DevX - Software Development Resource

Running other apps from a C++ app

Question: I recently started programming with Borland C++ Builder and the help files aren’t much help at all. I would like to know what the code is for executing another

DevX - Software Development Resource

Mixing delete and delete[]

Question: I am programming with Visual C++ 5.0 and the class library StarView from StarDivision.Looking at the Source from StarView, I found bad code: void** p = new (void*)[100];…delete p;

DevX - Software Development Resource

Include a Hits Counter Using ASP

If you’re using Internet Information Server with Active Server Page technology for hosting your Web site, here is a simple way to include a hits counter and the date the

DevX - Software Development Resource

Highlight Comments in your ASP Pages

If you’re using IIS 3.0 with Active Server Page technology for hosting yourWeb site, here is a very simple way to highlight comments in your ASP pages andreduce page download

DevX - Software Development Resource

Parameter Passing

Question: I am writing a program that needs to keep a running total of ID numbers allocated for this reason. The ID numbers are in an auto-increment field. I need

DevX - Software Development Resource

Max Calculation

Question: How do you select the maximum value of a column in a DBGrid when displayed through a query? (query SQL:select max(CustNo) from customer, and get error message:”the table is

DevX - Software Development Resource

Multiple Inheritance

Question: I read somewhere that Object Pascal, the language used in Delphi, does not support multiple inheritance. Is this true? Answer: Yes, this is true. Object Pascal’s inheritance model follows

DevX - Software Development Resource

Error Creating Window

Question: In my Delphi 1.0 application, when I open a form (e.g. ClientForm.Show) I get an error message: “Error creating window.” This error occurs when several forms (nine or ten

DevX - Software Development Resource

Access Violation Error

Question: I developed a database using AS400 components. Everything compiled and it was working for awhile. I have not changed anything in the project and now whenever I close the

DevX - Software Development Resource

Recommended Delphi Books

Question: I am looking for a good introduction book to Delphi. I know Turbo Pascal, but I am still a beginner in the field of OOP and in the field

DevX - Software Development Resource

Computing Number of the Week

Question: I want to compute the number of the week. Thanks in advance PLM Answer: This is pretty basic stuff. If you want the current week of the month, a

DevX - Software Development Resource

Delphi SQL Parameters

Question: Is it possible to use a parameter on the left side of an equality in a WHERE clause? For example: SELECT * FROM TblName WHERE:parm1 = :parm2 When I

DevX - Software Development Resource

ListBoxes and ItemData

Question: How can I expose the ItemData property of a ListBox to use it for storing longint data that corresponds to each item in the list in Delphi 3.0? I

DevX - Software Development Resource

Getting Application List

Question: How can I get a list of currently running applications and, more importantly, handles to their windows? Answer: For that you have to use the Windows API call, EnumWindows.

DevX - Software Development Resource

auto_ptr<>: your safe guard against memory leaks

The Standard Library supplies the class template auto_ptr which automatically deallocates heap memory. Likewise, local objects are reclaimed in case of exiting their scope or during “stack unwinding” caused by