Solved

UpCase limitation in french

Posted on 1998-01-15
4
136 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

Enroll in June's Course of the Month

June’s Course of the Month is now available! Experts Exchange’s Premium Members, Team Accounts, and Qualified Experts have access to a complimentary course each month as part of their membership—an extra way to sharpen your skills and increase training.

Question has a verified solution.

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

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …

729 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