Delphi Pages Forums  

Go Back   Delphi Pages Forums > Delphi Forum > General

Lost Password?

Closed Thread
 
Thread Tools Display Modes
  #1  
Old 11-05-2010, 10:39 AM
Ultima Ultima is offline
Member
 
Join Date: Nov 2002
Posts: 30
Default Create Word document with Cyrillic letters ?

Hello, gurus.

Maybe someone has an example, how to write something in MS Word document using english and cyrillic (russian) letters when using non russian regional settings, and Delphi 7 ? I can't even write russian code in editor, if regional settings is non russian

Best regards, Ultima

Last edited by Ultima; 11-05-2010 at 10:47 PM. Reason: I know how to create document :)
  #2  
Old 11-06-2010, 10:23 PM
Ultima Ultima is offline
Member
 
Join Date: Nov 2002
Posts: 30
Default

Ok, looks like i found ugly workaround... Put string into UTF-8 enabled mysql table (using PhpMyAdmin, for example), select it and put back to word document as variant...

Dokas.Tables.Item(1).Cell(1,1).Range.InsertAfter(d .QTemp.FieldByName('russian_one').AsVariant);

Maybe someone still have better solution ?
  #3  
Old 11-07-2010, 05:47 PM
Ultima Ultima is offline
Member
 
Join Date: Nov 2002
Posts: 30
Default

and finally, the simplest way (but hard to find for such newbie like me) - change windows regional settings to Russian, add Russian language to language bar, declare WideString variable, assign the Russian value - code editor now writes in Russian, and use it:
...
var russian_one:WideString
...
russian_one:='Государственный номер';
Doc1.Tables.Item(2).Cell(1,1).Range.InsertAfter(ru ssian_one);

Looks so simple ...
Closed Thread

Tags
cyrillic, ms word, unicode

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT. The time now is 05:30 AM.


Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2019, vBulletin Solutions, Inc.