C++C++11C++14C++17Language FeatureLearn C++

Tutorial: Learn To Copy Matrix As A Excel Clipboard In Modern C++

Clipboard also called the paste buffer, is a buffer that operating systems provide to copy things (texts, bitmaps, tables, etc.) for the short term and transfer within and between application programs. The clipboard is usually temporary and unnamed, and its contents reside in the computer’s memory.

In C++ Builder there are good components to use Excel forms, excel supported Grid components, etc. In this post, we would like to post a small snippet to copy a matrix member as in excel clipboard form. So you can paste all members to excel. This method is good to copy data from a matrix that is formed with numeric or alphanumeric parameters. You can also add this method to popup menus of components or things which has parameters in a table form, like Grids.

Excel form of a table (only texts) is formed with a text string and each column is separated with a tab character ( ‘\t‘ ) and each string line is listed as in that row.

This C++ Builder Console VCL Application example below copies a 2d matrix to a clipboard in excel form.


Oh hi there 👋
It’s nice to meet you.

Sign up to receive awesome C++ content in your inbox, every day.

We don’t spam! Read our privacy policy for more info.

About author

33+ years of coding with more than 30+ programming languages, mostly C++ on Windows, Android, Mac-OS, iOS, Linux and some other operating systems. Dr. Yilmaz Yoru was born in 1974, Eskisehir-Turkey. He graduated from the department of Mechanical Engineering of Eskisehir Osmangazi University in 1997. One year later he started to work in the same university as an assistant. He received his MSc and PhD degrees from the same department of the same university. He has married and he is a father of a son. Some of his interests are Programming, Thermodynamics, Fluid Mechanics and Artificial Intelligence. He also likes the graphical 2D & 3D design and high-end innovations.
Related posts
CC++Introduction to C++Learn C++

Who Wrote The C Programming Language?

CC++Introduction to C++Language FeatureLearn C++

Is C A High Level Programming Language?

CC++Introduction to C++Learn C++

How To Run A C Program in Command Prompt

CC++C++17Learn C++

How To Compile And Run A C Program