
Since 1998, DevX has helped people start businesses, build websites, and provide enterprise technology to people globally. Interviewing the likes of Microsoft’s co-founder, Steve Ballmer, the publication brings comprehensive, reliable, and accessible insights to the Internet.
If you develop applications that use components that need to be registered, consider setting up a shortcut to regsvr32 in the “Send To” folder on a user’s machine as part
Macros in C++ are better avoided. They are unsafe, hard to debug, and may bloat your .exe files. C++ offers significantly better alternatives to them: 1. Function-like macros should be
A non-explicit constructor taking a single argument is also a conversion operator, which casts its argument to an object of the constructor’s class. When the compiler has to resolve an
When two or more classes serve as base classes in multiple inheritance, you want to choose a distinct name for each member function in order to avoid name ambiguity: class
Void * can serve as a generic data pointer, yet it suffers from the well-known ailments associated with pointers: it can be NULL or a dangling pointer. Furthermore, it usually
Like ordinary functions, templates can have default type arguments. A good example is STL’s vector. It actually has two arguments–the second one is an allocator class template. Since an allocator
To allow the user to control long operations, use a single CommandButton to control starting and stopping a looping process: Dim Running As BooleanPrivate Sub CmdStartStop_Click() If Running Then ‘
It’s fairly common practice to add buttons to your date and numeric fields to allow users to select and display a popup calendar or calculator. However, to display a calculator
The algorithm shown in the tip, “Swap Values Using Only Two Variables” [“101 Tech Tips for VB Developers, Supplement to the February 1997 issue of VBPJ, page 25], crashes not
Arrays take less memory and are faster than collections. If you don’t need to use a collection’s keyed lookup, easy extensibility, and other features, use an array instead.
You can create complex shapes easily if you have a copy of Microsoft PowerPoint, CorelDraw, or any other graphics editor. Using your graphic editor’s drawing tools, draw the shape you
When creating applications, especially on an enterprise scale, don’t create them so that they run start to finish, tying up the user’s PC needlessly. If all you need is two
Question: I’ve developed a database using Microsoft Access, exporting the files to a Paradox 5 format. Now, the application I’ve developed that utilizes this database is currently running on two
Question: I am using the application.onhint example from the Delphi help files to put all hints in my status bar. It works on all but one form. I’m using the
Question: Is there a way to keep users from selecting, cutting, or copying text in HTML within a browser window? Or is there a way to embed text within HTML
Question: As a Web designer, one of my biggest struggles is JavaScript compatibility with previous browser versions (such as IE3, IE4, N2, N3, and N4). Is there a way I
Question: I’m trying to make outer join by the query builder in Delphi 2.0 but the only active option is inner join. I want to use left outer join and
Question: I want to be able to run an EXE file on a button click in one of my Delphi applications. Is it possible to do this? Where do I
Question: I tried your procedure for placing my application on the system tray and it works fine. My problem is that it opens the form1 when the application is executed,
Question: How can I add a new event to an existing component (for example, OnScroll to a TTreeView) without building a new ComponentClass? Answer: You can replace existing event handlers
Question: I have a form that uses one data source and one query component. The data set of the data source is the query. Depending on the process, I assign
Implement a low-tech trace of your application by writing a message whenever your code enters and exits a subroutine. This can help you locate elusive bugs, because you can turn
This function returns week identifier information, such as Week Beginning/Ending date, and makes it more generic to return a date of any previous or following weekday. You can use this
To make certain that you declared your variables, place Option Explicit in your Declarations section. Using a mixture of upper and lower case in variable names, you can easily verify
Question: I have an application with a lot of business logic in nonvisual objects that I’d like to deploy as DLLs callable as standard windows DLLs from applications written in
Question: How many DCOM connections can I have on a Windows NT Workstation? (Does it have a limit of 10, like in shares?) How is performance affected when 20 users
Question: I need to use the BDE in a Windows 3.11 environment. My Delphi 1 system does not include BDEINST material, although the help files refer to it. How can
Question: How do I add and remove users from an NT server through VB? I have Web customers who are added and removed frequently from our Web site, where they
The Windows 95 taskbar (with the Auto Hide check box set) is quite attractive and provides a compact, nonintrusive way to access and organize information. You can easily simulate this
Under VB3, IsDate returns True only if the string corresponds to the date format indicated by the “Regional” or “International” settings in the Control Panel. Under VB4 and VB5, however,
