Hallo all ,
Greetings to you ,
I am trying to write french accented characters é è ê in
Excel worksheet using my perl script , But I am stuck
here as I couldnt find a way of writing it !:

My code:

use strict;
use warnings;
use Win32::OLE qw(in with);
use Win32::OLE::Const 'Microsoft Excel';
my $Excel = Win32::OLE->GetActiveObject('Excel.Application')|| Win32::OLE->new('Excel.Application', 'Quit'); my $excel_file = 'd:/excelfile.xls';
And it goes on, where I am reading the french text from an
xml file and I am writing it into my Excel worksheet
using this :

$sheet->Cells($i,8)->{'Value'}="$temp"; Where $temp has the french text .. I see that It reads
correctly from the xml file.
my $xmlsource3 = "LAX03fr.xml";
open IN3, "<:utf8", $xmlsource3 or die "Can't Read Source
file $xmlsource3: $!\n";
There was a problem before with reading also but when I
added this "<:utf8" tag in there the problem got solved and
now it reads the characters correctly..

Also i printed the $temp in the output window and it shows
the accented characters correctly , only when it
writes to excel i cannot see the accented characters
and instead I see ,something like this in my excel ! ---> Unité
How can I solve this problem ?
Please help me guys , any help would be greatly appreciated.
thanks a lot, in advance,
shintu


In reply to Problem with Writing French Accented Characters in Excel using Perl! by shintu

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.