S
S
serheg2015-02-01 02:15:50
excel
serheg, 2015-02-01 02:15:50

How to change 1 parameter in 100 excel files?

Given: 100 excel files.
It is necessary to find and replace the word in all files.
Tell me how to do it?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex Teterin, 2015-02-01
@errogaht

In PHP, for example, write a simple script.
There is a popular PHPExcel class, there are many ready-made and working examples for it, just open the examples and see how it is done there and copy pieces from different examples into your final code, well, edit it. It's not difficult, if in Russian it will turn out something like this:
Folder = d:\files\
For all files in the "Folder" {
If file = *.xls
Add to FILES FILE
}
For all FILES {
Book = New instance of PHPexcel (FILE )
Sheet = Book.Open.First.Sheet of
Row = Get.Rows(Sheet)
For each Row {
If Tex.In.Row = LOOK FOR
THEN TEXT.IN.Row = REPLACE_TO_THIS
}
}
Well, of course, everything is not written in PHP like that, in English letters, but approximately the logic is like this, everything is just very simple, or you can do it in another programming language, I write simply in PHP.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question