in reply to Interpreting input file having special characters from multiple European languages

For reading in your Excel file, Spreadsheet::ParseExcel should handle all the characters properly. You can then use Text::Unidecode to convert your data to plain ASCII before printing to your output file - no special file handling required.
  • Comment on Re: Interpreting input file having special characters from multiple European languages

Replies are listed 'Best First'.
Re^2: Interpreting input file having special characters from multiple European languages
by Amphiaraus (Beadle) on Sep 16, 2015 at 15:49 UTC
    My Perl program for reading the multi-language Excel spreadsheet, and writing selected data to an ASCII *.ini file, uses the modules Spreadsheet::BasicRead and Spreadsheet::BasicReadNamedCol to read the Excel spreadsheet.

    The unmodified Text::Unicode module is not correctly translating Polish special characters while writing them into the ASCII *.ini file, the Polish special characters are garbled.

    I am using Strawberry Perl, which I assume is very out of date compared with standard Perl. Could this be causing my problem?

    Is there an alternate solution for the problems I am having in my Perl program?
      I am using Strawberry Perl, which I assume is very out of date compared with standard Perl.

      The Strawberry Perl project is very good at keeping up with releases from the main Perl project. The incantation perl -v will tell you the specific version you are running.

      The unmodified Text::Unicode module...
      May be a typo, but my suggestion was to use Text::Unidecode not Text::Unicode - they do quite different things. Spreadsheet::BasicRead should be fine as it uses Spreadsheet::ParseExcel under the hood.
        I made a typo in my reply I was using Text::Unidecode in my Perl program, not Text::Unicode.

        The CPAN entry for Text::Unidecode suggests modifying Text::Unidecode with special code for any language (such as Polish) whose special characters cause problems for Text::Unidecode. I was hoping to avoid this.