createobject and greek characters

Post Reply
JimTheo
Posts: 15
Joined: Thu Sep 21, 2006 5:01 pm

createobject and greek characters

Post by JimTheo »

When I use an external object using createobject() or ActiveX I cannot read or write greek characters.
For example if you change, into excel2.prg (to samples folder) the line
oSheet:Range( "B2" ):Value = "John"
as
oSheet:Range( "B2" ):Value = "Γιάννης"
// something like oSheet:Range( "B2" ):Value = "Giannis"

The result into B2 is unreadable.
Is there any way to read or write greek caharacters?

I have the same problem when i use CreateObject("Microsoft.XMLDOM") to read xml files with ANSI or utf8 data.
JimTheo
Posts: 15
Joined: Thu Sep 21, 2006 5:01 pm

Re: createobject and greek characters

Post by JimTheo »

Is there any news for this topic?
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Re: createobject and greek characters

Post by Antonio Linares »

Could someone with Excel installed try this ?

We don't use MS Office anymore since years...
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: createobject and greek characters

Post by Enrico Maria Giordano »

Jim,

it's probably your editor that lost the unicode characters. Please note that [x]Harbour won't compile unicode source code anyway.

EMG
JimTheo
Posts: 15
Joined: Thu Sep 21, 2006 5:01 pm

Re: createobject and greek characters

Post by JimTheo »

Enrico
The same problem occures when I open an xml file using CreateObject("Microsoft.XMLDOM"). I cannot read Greek characters.
JimTheo
Posts: 15
Joined: Thu Sep 21, 2006 5:01 pm

Re: createobject and greek characters

Post by JimTheo »

Finally I used the following statements.
REQUEST HB_CODEPAGE_ELWIN
hb_setcodepage('ELWIN')

But i need to change codepage to any function i use. Is there any way to set it public to program?
Post Reply