Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

How can I let memo to display character µ

Posted on 2006-04-18
9
Medium Priority
?
308 Views
Last Modified: 2013-12-03
Hi

How can I let memo display µ or write µ into a text file?

Memo1.text := #230  
The memo1 will display æ not µ

Thank u

Peter
0
Comment
Question by:petershaw9
  • 4
  • 2
7 Comments
 
LVL 11

Expert Comment

by:ZhaawZ
ID: 16484424
It shows you (ae) because of the font/charset you're using (it's default_charset by default). Try this:
Memo1.Font.Charset := OEM_CHARSET;
Memo1.Text := #230;
0
 
LVL 11

Expert Comment

by:ZhaawZ
ID: 16484444
ah, no, it's not the same character, sorry (looks only similar on my pc). However you may try #181 instead of #230

memo1.Font.Size := 12;
Memo1.Text := #181;
0
 

Author Comment

by:petershaw9
ID: 16484846
In the ascii table µ should be #230. If use #182 then it will be hard to auto display the other spcecial character.
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 11

Expert Comment

by:ZhaawZ
ID: 16486677
wich ascii table did you use?
as far as i know, only first 127 chars are "fixed", i.e., do not depend on font/charset.
0
 
LVL 9

Expert Comment

by:bernani
ID: 16492954
Like this (works on my XP system - default 'MS Sans Serif' font and 'DEFAULT_CHARSET'):

memo1.SelText := #$03BC;



0
 

Author Comment

by:petershaw9
ID: 16493825
I have a copy of ASCII table, but I forgot where it is from. Using this table I can correctly type these special character on delphi, notepad and here. like 224 is α, 225 is ß, 226 is Γ, 227 is π, 128 is Ç, 129 is ü.

So this like font, charset independent. Something about windows. Think I can change font, charset for memo control, but how about write this into textfile?

Peter
0
 
LVL 11

Accepted Solution

by:
ZhaawZ earned 1000 total points
ID: 16497219
This DEPENDS on a charset/font you're using. 225 does not give me that symbol which looks like "B", 128 does not give me smth like "C" and 129 does not give me smth like "u" (those are 223 for "B" and 252 for "u" with baltic charset, and there are NO such symbols in cyrillic charset).

To make this working on all PCs, you'll have to use (1) correct font/charset or (2) unicode.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
Suggested Courses

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question