473,386 Members | 1,997 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Writing French Accented Characters in Excel using Perl.

1
Hallo,

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:

Expand|Select|Wrap|Line Numbers
  1. use strict;
  2. use warnings;
  3.  
  4. use Win32::OLE qw(in with);
  5. use Win32::OLE::Const 'Microsoft Excel';
  6.  
  7. my $Excel = Win32::OLE->GetActiveObject('Excel.Application')
  8.     or Win32::OLE->new('Excel.Application', 'Quit');
  9. my $excel_file = 'd:/excelfile.xls';
  10.  
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 :

Expand|Select|Wrap|Line Numbers
  1. $sheet->Cells($i,8)->{'Value'}="$temp";
  2.  
Where $temp has the french text .. I see that It reads correctly from the xml file.

Expand|Select|Wrap|Line Numbers
  1. my $xmlsource3 = "LAX03fr.xml";
  2. open IN3, "<:utf8", $xmlsource3 or die "Can't Read Source file $xmlsource3: $!\n";
  3.  
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
Sep 6 '07 #1
0 2267

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Bernhard Georg Enders | last post by:
I'm using the php 'file' command to read the contents of an ASCII text file to a variable. The original text file contains some accented and special characters. The problem arises when I echo this...
2
by: Si Pearson | last post by:
Hi, I've got an aspx page with a 'mailto' with accented characters in the subject field, when the mail is created the accented characters aren't displayed correctly. The mailto looks like...
2
by: yearTiger2002 | last post by:
Our company's back end database server does not handle french accentuated characters well. We need to replace those characters with english letters when validating the form inputs. Any suggestions?...
0
by: Mark Drummond | last post by:
I don't do a lot of perl, but what I do usually always involves working with data in LDAP directories. I have a script now that I run every Monday to produce a CSV file containing a dump of some...
2
by: ngrover | last post by:
When accessing strings from a french language utf-8 .txt file (that has been resgen'ed into a .resources file) via ResourceManager.GetString() method, I am encountering a problem. All the special...
1
by: jgershonw1 | last post by:
I have a file that is UTF-8 encoded which contains french words. The french characters are represented as two characters. Take for example an accented e, which is A with a tilda ontop and the...
1
by: rvenable | last post by:
Hi everyone, I'm new to this forum and I hope I'm in the right one. I have a question regarding MS Index server to search for french accent characters. I have a search engine for our website that...
4
by: gsuns82 | last post by:
Hi all, I am facing a strange issue. i.e: I have a jsp page with an input text field where the user can enter searching value even along with Accented Characters.After that i...
0
by: jpero09 | last post by:
Having some trouble writing out accented characters to an ms-excel type output from my asp.net page (c#). I've tried a few different charsets but every time the è on my page is getting rendered as...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.