Home > Back-end >  How in Delphi import excel reading excel data
How in Delphi import excel reading excel data

Time:09-30

Project to do want to follow the teacher, the teacher arranged "Delphi import excel reading excel data" this topic, but doesn't come into contact with the software before, hope everybody can help me, how to implement this feature, the statement is the basic look not to understand, in the homework tomorrow!

CodePudding user response:

Don't give you a excel? Dad didn't give you the teacher is a pit,

CodePudding user response:

An excel casually, as long as there is data!

CodePudding user response:

Resource ID: 4538264

CodePudding user response:

If you just want to know how to read, you asked than that of baidu, Delphi excel

CodePudding user response:

Students are now even Google, baidu all don't understand?

CodePudding user response:

Are generally in baidu can not find to come to for help

CodePudding user response:

Query directly with ADO, Excel

CodePudding user response:

1, the use of ADO, the EXCEL file as an ADO input source;
2, the use of third party components, such as XLSReadWriteII or NativeExcel;

Personally recommend using a third party controls, speed, strong function, compatibility, especially NativeExcel, flexible, need I can send you, NativeExcel 3.0.26,

CodePudding user response:

XLSReadWriteII

CodePudding user response:

Resource ID: 4538264

CodePudding user response:

NativeExcel

CodePudding user response:

Should have other specific function is introduced, impossible is a word, where such as excel import, read a what kind of excel, even when no will you also go to ask the teacher, the teacher will do later when the actual project, the communication with customer is very important,

CodePudding user response:

ADO to connect directly to EXCEL as a database file type

CodePudding user response:

Use OLE links

CodePudding user response:

Resource ID: 4538264

CodePudding user response:

It is recommended to use XLSReadWriteII, powerful, statements and simple, and fast speed,
Also can use D in the Servers controls,

CodePudding user response:

The building Lord how don't show up?

CodePudding user response:

NativeExcel how to import the EXCEL data??????????? Open the file path of function

CodePudding user response:

Import can also such, should have a lot of examples, online
Var
PExcel: Variant;
///////
PExcel:=CreateOleObject (' Excel. Application);

PExcel. WorkBooks. Open (' c: \ aa. XLS);

PExcel. Worksheets [1]. Activate;

RowCount:=pExcel ActiveSheet. UsedRange. Rows. Count;
The ColumnCount: pExcel.=ActiveSheet. UsedRange. Columns. The count;
For I:=1 to RowCount do
The begin
For J:=1 to ColumnCount do
The begin
TmpCellVal:=pExcel. ActiveSheet. Cells [I, J] Text;
End
End
  • Related