Tip Bank

DevX - Software Development Resource

Java interfaces and constructors

Question: Is there a way to force a specific constructor with an interface? Answer: No, there is no way to force implementors of a given interface to use constructors with

DevX - Software Development Resource

C/C++ system() equivalent

Question: Does Java have a command that does what thesystem() function does in C, or a way to emulatethis action? For example, in C, system(“ls”); would call “ls” from the

DevX - Software Development Resource

Windows Programming (custom windows)

Question: I am trying to program my own custom controls in C++ in the old, traditional style (using WNDPROCS, etc.), and I don’t want to use ActiveX. I’d like to

DevX - Software Development Resource

C vs C++

Question: What is the main difference between Visual C and Visual C++ in Windows environments? Why would I want to use C++ instead? Is there any functional difference? Answer: Well,

DevX - Software Development Resource

Applets, URLs, and frames

Question: I want my Web page to have three frames: one for my applet and the other two for information. How can I make it so my applet updates both

DevX - Software Development Resource

Converting text to a binary code

Question: I’m using Borland C++ to perform some data conversion, and I have had some difficulties. Is it possible to convert all the text (including nonreadable text) within a text

DevX - Software Development Resource

Text Area and Cursor Control

The java.awt.TextComponent class (from which TextArea is derived) has three methods to retrieve mouse selection information. The getSelectedText() method will return a String containing the selected text, and the getSelectionStart()