Solved

UpCase limitation in french

Posted on 1998-01-15
4
135 Views
Last Modified: 2010-04-04
I need to upcase the first letter of a string. But when the the first caracter contain an accent (eg. e acute or a grave)the UpCase fonction let it in downcase. Any idea!
0
Comment
Question by:pjroy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 4

Accepted Solution

by:
itamar earned 100 total points
ID: 1356840
Hi,

You must use AnsiUpperCase.

IHTH

0
 
LVL 5

Expert Comment

by:julio011597
ID: 1356841
Or write a few lines of code, in order to be sure your code works on any machine.

Let me know if you need it.
0
 

Author Comment

by:pjroy
ID: 1356842
I use code like the one above to upcase only the first, but I got an imcompatible type error.

descrition: string
description[1] := AnsiUpperCase(description[1]);

Can you help me on the use of string type
0
 
LVL 4

Expert Comment

by:itamar
ID: 1356843
Hi pjrov,

Your question induced me to focus in the accent problem.
I guess you had the same type error with UpperCase, don't you ?

The best conduct in such case would be placing a comment before grading the answer - you gave me a B )-:<

Anyway, I think I can help you. Change your code to:

descrition: string
description[1] := AnsiUpperCase(description[1])[1];

No, this is not a mistyping !!! I know it looks strange but it works...

IHTH

P.S.: If you want a piece of code that upcases (?) the first letter of a text while it is being typed by the user in a edit or combo box, place another question and I can send it for you. Bye.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…
Finding and deleting duplicate (picture) files can be a time consuming task. My wife and I, our three kids and their families all share one dilemma: Managing our pictures. Between desktops, laptops, phones, tablets, and cameras; over the last decade…

740 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