Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / May 2008

Tip: Looking for answers? Try searching our database.

Button to insert Symbol

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jacky - 08 May 2008 01:08 GMT
Hi, I'm currently preparing a form on which some unique symbols are to be
used on the inputting. Since this symbols are not conveniently available on
the english keyboard inputs, I'm thinking to create buttons for these
symbols, where when clicked, the symbols will be paste on to the current
cursor location and the user be able to continue the inputing, in the same
field after the newly inserted symbol.
Linq Adams - 08 May 2008 02:53 GMT
You don't say where you getting these symbols from, so I'll just show you the
code you need using an ampersand. You can use Windows Character Map to find
them or insert them from another source.

Private Sub InsertAmpersand_Click()
 Screen.PreviousControl = Screen.PreviousControl & "@"
 Screen.PreviousControl.SetFocus
End Sub

You can return focus to the textbox involved with

Screen.PreviousControl

but you can use it with SelStart to send the cursor to the end of the data
after the insertion, so you need to do this for each possible textbox that
you'll be using this with:

Private Sub TextBox1_Enter()
 TextBox1.SelStart = Nz(Len(Me.TextBox1), 0)
End Sub

Private Sub TextBox2_Enter()
 TextBox2.SelStart = Nz(Len(Me.TextBox2), 0)
End Sub

and so forth. Enter data in whatever field you need to, then when necessary,
click on the insert button, and the special character, in this case an
ampersand,   will be inserted in that field and the cursor will return to the
end of the data in the field, ready for the next character.

Signature

There's ALWAYS more than one way to skin a cat!

Answers/posts based on Access 2000/2003

Jacky - 08 May 2008 04:54 GMT
Thanks Linq,

Perfect solution to my question. Thanks thanks.

> You don't say where you getting these symbols from, so I'll just show you the
> code you need using an ampersand. You can use Windows Character Map to find
[quoted text clipped - 25 lines]
> ampersand,   will be inserted in that field and the cursor will return to the
> end of the data in the field, ready for the next character.
Jacky - 20 May 2008 09:40 GMT
Hi Linq,

New add-on to the problem:

Method highlighted previously worke for normal symbol like ampersand or ohms.
However this would not work for those symbols arrows (horizontal and down
arrows) from fonts Windings 3.

How can I make use of these symbols? The coding part I'm unable to copy and
paste in the symbol correctly.

Thanks for the helping.

> You don't say where you getting these symbols from, so I'll just show you the
> code you need using an ampersand. You can use Windows Character Map to find
[quoted text clipped - 25 lines]
> ampersand,   will be inserted in that field and the cursor will return to the
> end of the data in the field, ready for the next character.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.