Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

pound and copyright symbols

pound and copyright symbols

pound and copyright symbols

one PC (just one) with my VFP9 .exe installed is showing

� instead of a pound sign

and the unknown character symbol (diamond+?) instead of copyright.

These values aren't coming from a table but a hard coded character string.

The Windows regional settings are UK, no extra codepages or keyboards installed (that i can see) but i've just been told the PC came with German installed (but now uninstalled).

Anyone seen similar? I'm hoping not to have to tell the user to reinstall windows.


RE: pound and copyright symbols

What does the string actually contain? And how did you create the string?

If you typed a pound sign on your UK keyboard, that should be stored as CHR(163). Is that what you are seeing? The same would apply if you typed ALT+156. If you typed ALT+163, you would get a lower-case u with an acute accent.


Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads

RE: pound and copyright symbols

the copyright symbol appears in a VFP form's label. The pound sign in a textbox (but disappears because of the way i change the .inputmask property in the .when() event.)

So i can't easily get the actual values. But the copyright symbol is hard coded with

thisform.lblCopyright.CAPTION = "© Nigel Gomm 1995 - "+STR(YEAR(DATE()),4)+" All Rights Reserved."

i overrode the set sysformat with a set currency and am waiting to hear if that fixed that at least.

i'll try and gain access to the PC in question and experiment in the command window.


RE: pound and copyright symbols

SET CURRENCY shouldn't affect values stored within strings. It mainly only affects currency data types, or conversions such as with TRANSFORM(lnAmount, "@$").

Your caption code looks exactly right to me. The only thing I can think of off-hand is to check that the target font actually contains a pound symbol (in the expected position). If the label has some unusual font, just try setting it to Arial as a test.


Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads

RE: pound and copyright symbols

i should stress this same .exe is installed on about 3 or 4 thousand PCs around the country. Just this one PC playing up.

with the pound sign it was in currency conversions such as transform, inputmask or printed in reports that the problem was showing.

hmmm.... the font is 'Segoe UI'. i'll make sure it's installed.


RE: pound and copyright symbols

Of course, you could get at the ASC values of the displayed character with ASC(left(this.caption,1)) and similar.

You can also find out what codepages are assigned to each of your project files via:


For each loFile in _vfp.ActiveProject.Files
   ? loFile.codepage, loFile.name

But when the binary EXE is the same this won't differ unless you only think it is the same EXE from the same build. The only things that remain are ANSI code page used by the system or font anomalies, missing fonts leading to the OS using a replacement font.

I can just assure you, that a German Windows (10) a) uses the Latin1 ANSI codepage 1252 and b) both copyright and pound characters are present and are the byte codes 163 for the pound symbol and 169 for the copyright symbol.

Windows has overrides for non-Unicode applications as VFP executables are. So it may still pay to look into the Windows system regional settings in detail.

And otherwise, fonts, as already suggested by yourself and Mike. I see Segoe UI is a standard Windows font replacing Tahoma, but if this is XP that's not the case. Segoe was introduced in Vista and I'm not finding whether that already was Segoe UI or just Segoe.

What you show here rather looks like a misconverted UTF-8 character, though, which actually is not converted, but stayed in the 2 bytes the character is in UTF-8. And � actually are the bytes that make up a � character in UTF-8, so it looks like some character encoding conversion failed and from that sometimes the Unicode character is displayed as-is: �. And sometimes it's displayed as its two bytes and their two ANSI characters �. Are you using Webbrowser control or any Unicode capable controls like RTF control?

If you don't do any string conversion calls like STRCONV() the only way I know you can step on your own foot nowadays is via this beta feature option of Windows 10:

Bye, Olaf.

Olaf Doschke Software Engineering

RE: pound and copyright symbols

good shout Olaf.

in language settings, administrative language settings, change system locale

you can get that region settings dialog back and unset the 'beta' checkbox.

and now all is well.



RE: pound and copyright symbols

I had experimented with this, but the whole thing then will depend on the user also having that setting.
You don't naturally get some characters typed in anymore, so you'd need some keyboard mapping within the IDE and more.
And in beta status you still never know whether the workarounds you find out will finally work.

Bye, Olaf.

Olaf Doschke Software Engineering

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close