Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

How to implement pattern nmatching and then inserting data in a XLS file

by Anonymous Monk
on Oct 05, 2012 at 09:16 UTC ( #997415=perlquestion: print w/replies, xml ) Need Help??
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Hi Monks,

Can you guys , let me know that how to find any string from a xls file?

Once the pattern is found, then only rewrite that string by some other string

I'm an expertise in text file modifications, but I'm not sure in case of XLS

  • Comment on How to implement pattern nmatching and then inserting data in a XLS file

Replies are listed 'Best First'.
Re: How to implement pattern nmatching and then inserting data in a XLS file
by grizzley (Chaplain) on Oct 05, 2012 at 10:11 UTC
    You can convert .xls to .csv format and then do simple text search (and replace) in text file.
      and then I will again convert it into xls, don't you think it will be too much time consuming??

        Yes, I agree. That's just one of solutions and I check Excel modules on CPAN, but until now have found only modules like Excel::Writer for creation of Excel worksheets and without simple 'find and replace' function.

        I guess the best approach for you would be to use Win32::OLE module, example with using 'find' function is presented here Re: Win32::OLE Excel search and replace commas (adapting it to find & replace should not be hard).

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://997415]
Approved by Corion
help
Chatterbox?
[zentara]: erix I hope both tusks pointed in the same direction :-)
LanX "♪..♫ Last night a DJ killed my wife ♪..♫ "
zentara...oO 1 more reason I prefer Perl to Python is I can't believe how long Python takes to compile, and you can't disable the myriad of tests
[LanX]: so that's where you've been the last two years? Compiling Python?
[zentara]: LanX no! I was learning why Krishna made me into a unicorn. :-)

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (6)
As of 2017-03-30 16:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (361 votes). Check out past polls.