Button to insert Symbol 2

J

Jacky

Hi,

Actually I had posted add-on to my previous post "Button to insert Symbol",
however there doesn't seems to have any further reply from there. Not too
sure if it's due to me checking helpful that's why no response or there's no
offered solution.

Anyway, in the previous post, the initial solution was:
Private Sub InsertAmpersand_Click()
Screen.PreviousControl = Screen.PreviousControl & "@"
Screen.PreviousControl.SetFocus
End Sub

This is workable for all normal text symbols. However, for none normal text
symbols like 'Downwards Arrow With Tip Rightwards' from Wingdings 3 font, it
is not workable with this method. Even on this posting, when i just cut and
paste the symbol from words, it becomes like this .

From some trial and error, what I see is that the field is able to display
the character correctly, only when the filed font type is converted to
Wingdings 3. However, the intention to insert the symbol, is to use symbol
description with other text inputs.

Hope to hear some response...your help is appreciated.
Thanks.
 
A

Albert D. Kallal

This is workable for all normal text symbols. However, for none normal
text
symbols like 'Downwards Arrow With Tip Rightwards' from Wingdings 3 font,
it
is not workable with this method. Even on this posting, when i just cut
and
paste the symbol from words, it becomes like this ?.

From some trial and error, what I see is that the field is able to display
the character correctly, only when the filed font type is converted to
Wingdings 3. However, the intention to insert the symbol, is to use symbol
description with other text inputs.

Hope to hear some response...your help is appreciated.
Thanks.

The problem (as you correctly identified above) is of course that you can't
have different fonts mixed in a text box control. (note that the exception
to this is to use a memo field in access 2007, in which it does allow
different types of fonts and even underlining and bold and in the control,
but I only recommend that for big blocks of text, not a regular field as
that control must be used AS A memo field. (and memo fields can't be
indexed, so it's not a practical solution for most regular fields on the
screen).

However virtually all the standard fonts such as an arial, times new Roman,
tahoma etc. all have all the symbols are looking for. At least I think they
do, (you'll have to explain further which characters you want).

To see which symbols are available in the font (character set) that you're
using, simply fire up bit character map accessory.

You find it:

start->All programs->Accessories->system tools->character map

Note the scroll bar on the map, if you scroll down towards the end, you'll
see the copyright symbols, and all the arrow keys, and probably a few others
you might want to use.

Note that the character map also has an advance view check box ( you to
check that option). The key code for the synbols you click on with your
mouse is display down below.


For example for the up arrow, I find a value of 2193 (that is a hex value),
so, in code, you can add a down arrow synbol in a text box like:


Screen.PreviousControl = Screen.PreviousControl & charw(&h2193)

You can also use the debug.window, and go:

? &h2193
8595

so,

Screen.PreviousControl = Screen.PreviousControl & charw(8595)

So give the above a try, if you bring up the character map for a font, it
does all kinds symbols like to trademarks symbol, the copyright symbol, and
all of the arrow keys and a number of others.

charw() is able to return a unicode character, where the function chr() is
limited from 0-255.

since all the fonts and modern windows is actually a unicode, then the
allowable number range is 0-65,000
 
J

Jacky

Hi Albert,

Thanks for the reply and the limitation of Access 2003.
Think I would just have to souce for alternative representation for the
inputs. (Previous choice of the downwards right arrow, is a direct
continuation of the paper recording practice.)

Also, glad to learn of the Chr() and ChrW() functions.
Thanks for the assistance.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top