Fortran-based DLL and Excel VBA are good fit for marriage.

Yes Fortran-based DLL and Excel VBA are made for each other.

Before i delve into why, lets understand what is a DLL and what are its advantage.

A dynamic-link library (DLL) contains one or more subprograms that are compiled, linked and stored separately from the applications using them. A DLL can also be used as a place to share data across processes.

Advantages of DLLs
1. As long as the functions’ arguments and return types do not change, you can can change functions in a DLL without recompiling and relinking applications that use it.

2. Common blocks or module data placed in a DLL can be shared across multiple processes.

3. Since general functions can be placed in DLLs, the applications that share the DLLs have smaller executable.

4. Multiple applications can access the same DLL. This reduces the overall amount of memory needed in the system.

Now the original question why Fortran based dll and excel vba make a good pair?

The basic Fortran types of INTEGER, LOGICAL and DOUBLE PRECISION map directly on to the Excel types of Long, Long and Double respectively.

In addition Fortran array storage is directly comparable to the array storage conventions used in Excel. Like Fortran VBA arrays are stored by column and are thus compatible with Fortran.


2 thoughts on “Fortran-based DLL and Excel VBA are good fit for marriage.

  1. Pingback: Fortran DLL and Excel «

  2. Pingback: An Excel App for Your Brain! |

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s