Tip Bank

DevX - Software Development Resource

What Is a Thunk?

The term thunk dates back to the days of the antediluvian Algol programming language and has stuck since then. A thunk is an invisible and parameter-less function or procedure that

DevX - Software Development Resource

DLLs and Dynamic Memory Allocation

Dynamic linking — either in the form of shared libraries in Unix or Windows DLLs — is not defined by standard C++. However, this is a widely used feature among

DevX - Software Development Resource

Obtain Exception’s Stack Trace as String

It is sometimes necessary to get the exception’s stack trace as String (for logging, reporting, etc.). Unfortunately, the Exception class itself provides only the getMessage() method which does not include

DevX - Software Development Resource

Variadic Macros

The concept of a variable argument list is rather common: void f(const char *format,

DevX - Software Development Resource

Provide

It is often helpful to provide a

DevX - Software Development Resource

Passing a UDT(User-Defined Type) Between Forms

There is a very simple way to get around the compile error when passing UDT (user-defined type) in procedure between forms. Just declare the procedure as Friend instead of Public.Example:

DevX - Software Development Resource

Resize the Column Headers to Fit the ListView

This function resizes the column headers to fit the ListView. It can be used in the Form_Resize event or just in Form_Load. ‘Module: Module1Option ExplicitPrivate Type RECT Left As Long