Site icon Embarcadero RAD Studio, Delphi, & C++Builder Blogs

Use the Excel.Application in C++Builder(bcc64)[JAPAN]

Author: Pixelot12345

How to use the Excel.Application in C++Builder. Target device is Win64.

Use the ComObj, call in CreateOleObject (“Excel.Application”).

Including ComObj is required.

In C++Builder it is below.

[crayon-67403356e8560664505993/]

Import from CSV file to Excel file.

[crayon-67403356e856a905259108/]

We will implement this process.

Prepare the TButton.

TButton is one in a simple form.

 

Next is the TButton OnClick event.

[crayon-67403356e856c919607084/]

 

Sheet name is “Sheet 1”.

Next we will create two methods.

[crayon-67403356e856e854611282/]

Read the file with TStringList.And, you write to the specified cell.

 

[crayon-67403356e8573836107612/]

Write the imported CSV file to Excel.

 

 

 

Exit mobile version