Code Library

Free Source Code and Program Tips

Some useful shortcut of Visual Studio 6

Hide/Show white spaces: Ctrl+Shift+8 Column Selection Alt+Mouse SelectLine Ctrl+F8 LineCut Ctrl+L LineDelete Ctrl+Shift+L

A powerful math function parser(zz)

by Andreas Jdger The inspiration to write this code was to have an easy-to-use parser for functions given as string. You have a string like cos(x)-7*x/(1+x) and you want to compute some values, maybe for displaying the graph of the function. You can write code like this: CFunction* fkt = CFunction::Parse(“cos(x)-7*x/(1+x)”); long double y = [...]

We often meet such case: I have an application with a modeless dialog. The dialog comes up perfectly in DEBUG build, But in RELEASE build, it crashed. Such problem often occures because of incorrect signature of message handle functions, that included into MFC message map for your CWnd based class.We should very carefully check signatures [...]

Nullsoft Scriptable Install System v2.22

NSIS (Nullsoft Scriptable Install System) is a professional open source system to create Windows installers. It is designed to be as small and flexible as possible and is therefore very suitable for internet distribution. Being a user’s first experience with your product, a stable and reliable installer is an important component of succesful software. With [...]

ucoGrid, a great grid control of MFC

UcoGrid is develped from CGridCtrl, and provides more exciting features. CGridCtrl is a great ctrl developed by Chris Maunder, which can display and edit tabulated data and support custom defined cell type. The lastest version is Here. Many developers have created their new cells and developed new feathers for CGridCtrl. such as, merging and unmerging [...]

Here is only a short introduction of the article, if you are interested, please goto the author’s website for the full text. Most people have heard of the standard auto_ptr smart pointer facility, but not everyone uses it daily. That’s a shame, because it turns out that auto_ptr neatly solves common C++ design and coding [...]

Question I have a text file with a lot of lines, and in each line, there are several columns divided by space character, but the number of columns in each line varies. For example, here is a sample ——————– abc 123 234 456 bsc 3 5 7 9 10 123 yyt 23 ——————– I want [...]

What is the usage of WM_NULL?

Alex Rest found the WM_NULL message and was curious where somebody would need to use that. I have found a strange Windows message. It is described in MSDN so: WM_NULL: The WM_NULL message performs no operation. An application sends the WM_NULL message if it wants to post a message that the recipient window will ignore. [...]

Write and read binary data in VARIANT

We offen need to store some binary data in the mdb database, thus we have to transefer the data by VARIANT structure.But how to read from binary data from VARIANT or write to? Here is a solution by safe array of VARRIANT.

Formula Parser Formular Editor, a great control which can edit and display the formular in a very friendly way. For details, please visit the CodeProject website. But how to build the formula is very hard. One can input the formula by the mouse, or build the Formular Tree in program. Both are hard. So I [...]