Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How to change font of ToolTip

Posted on 2002-04-21
9
Medium Priority
?
246 Views
Last Modified: 2013-12-02
Dear Friends,
   I am developing a software with regional lnaguage support. When that software is run I want to display the tooltips in language related with that software in the local language. Wsing win API's is the solution. I am looking in that way. Please let me know your views abt it.
Thank you,
Regards,
       bhatul
0
Comment
Question by:bhatul
[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
9 Comments
 
LVL 33

Accepted Solution

by:
hongjun earned 200 total points
ID: 6957493
Custom ToolTips Dll (Version 2.0)
http://www.freevbcode.com/ShowCode.Asp?ID=1232



hongjun
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 6958064
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 6958477
You need to know local language configuration and load tooltip strings according it.
To know which language is:
(this is a general use to get all values from locale config, modify as you wish)

Option Explicit
'These declarations are designed
'for use in a .bas module
'since the constants are public


Declare Function GetLocaleInfo Lib "kernel32" Alias _
"GetLocaleInfoA" (ByVal Locale As Long, ByVal LCType As Long, _
ByVal lpLCData As String, ByVal cchData As Long) As Long

Declare Function SetLocaleInfo Lib "kernel32" Alias _
"SetLocaleInfoA" (ByVal Locale As Long, ByVal LCType As Long, _
ByVal lpLCData As String) As Boolean

Declare Function GetUserDefaultLCID% Lib "kernel32" ()
Public Enum LOCAL_INFO
 LOCALE_ICENTURY = &H24
 LOCALE_ICOUNTRY = &H5
 LOCALE_ICURRDIGITS = &H19
 LOCALE_ICURRENCY = &H1B
 LOCALE_IDATE = &H21
 LOCALE_IDAYLZERO = &H26
 LOCALE_IDEFAULTCODEPAGE = &HB
 LOCALE_IDEFAULTCOUNTRY = &HA
 LOCALE_IDEFAULTLANGUAGE = &H9
 LOCALE_IDIGITS = &H11
 LOCALE_IINTLCURRDIGITS = &H1A
 LOCALE_ILANGUAGE = &H1
 LOCALE_ILDATE = &H22
 LOCALE_ILZERO = &H12
 LOCALE_IMEASURE = &HD
 LOCALE_IMONLZERO = &H27
 LOCALE_INEGCURR = &H1C
 LOCALE_INEGSEPBYSPACE = &H57
 LOCALE_INEGSIGNPOSN = &H53
 LOCALE_INEGSYMPRECEDES = &H56
 LOCALE_IPOSSEPBYSPACE = &H55
 LOCALE_IPOSSIGNPOSN = &H52
 LOCALE_IPOSSYMPRECEDES = &H54
 LOCALE_ITIME = &H23
 LOCALE_ITLZERO = &H25
 LOCALE_NOUSEROVERRIDE = &H80000000
 SymbolAM = &H28
 SymbolPM = &H29
 LOCALE_SABBREVCTRYNAME = &H7
 LOCALE_SABBREVDAYNAME1 = &H31
 LOCALE_SABBREVDAYNAME2 = &H32
 LOCALE_SABBREVDAYNAME3 = &H33
 LOCALE_SABBREVDAYNAME4 = &H34
 LOCALE_SABBREVDAYNAME5 = &H35
 LOCALE_SABBREVDAYNAME6 = &H36
 LOCALE_SABBREVDAYNAME7 = &H37
 LOCALE_SABBREVLANGNAME = &H3
 LOCALE_SABBREVMONTHNAME1 = &H44
 LOCALE_SCOUNTRY = &H6
 LOCALE_SCURRENCY = &H14
 LOCALE_SDATE = &H1D
 LOCALE_SDAYNAME1 = &H2A
 LOCALE_SDAYNAME2 = &H2B
 LOCALE_SDAYNAME3 = &H2C
 LOCALE_SDAYNAME4 = &H2D
 LOCALE_SDAYNAME5 = &H2E
 LOCALE_SDAYNAME6 = &H2F
 LOCALE_SDAYNAME7 = &H30
 LOCALE_SDECIMAL = &HE
 LOCALE_SENGCOUNTRY = &H1002
 LOCALE_SENGLANGUAGE = &H1001
 LOCALE_SGROUPING = &H10
 LOCALE_SINTLSYMBOL = &H15
 LOCALE_SLANGUAGE = &H2
 LOCALE_SLIST = &HC
 LOCALE_SLONGDATE = &H20
 LOCALE_SMONDECIMALSEP = &H16
 LOCALE_SMONGROUPING = &H18
 LOCALE_SMONTHNAME1 = &H38
 LOCALE_SMONTHNAME10 = &H41
 LOCALE_SMONTHNAME11 = &H42
 LOCALE_SMONTHNAME12 = &H43
 LOCALE_SMONTHNAME2 = &H39
 LOCALE_SMONTHNAME3 = &H3A
 LOCALE_SMONTHNAME4 = &H3B
 LOCALE_SMONTHNAME5 = &H3C
 LOCALE_SMONTHNAME6 = &H3D
 LOCALE_SMONTHNAME7 = &H3E
 LOCALE_SMONTHNAME8 = &H3F
 LOCALE_SMONTHNAME9 = &H40
 LOCALE_SMONTHOUSANDSEP = &H17
 LOCALE_SNATIVECTRYNAME = &H8
 LOCALE_SNATIVEDIGITS = &H13
 LOCALE_SNATIVELANGNAME = &H4
 LOCALE_SNEGATIVESIGN = &H51
 LOCALE_SPOSITIVESIGN = &H50
 LOCALE_SSHORTDATE = &H1F
 LOCALE_STHOUSAND = &HF
 LOCALE_STIME = &H1E
 LOCALE_STIMEFORMAT = &H1003
End Enum
Public Function Get_locale(RSValue As LOCAL_INFO) ' Retrieve the regional setting

     Dim Symbol As String
     Dim iRet1 As Long
     Dim iRet2 As Long
     Dim lpLCDataVar As String
     Dim Pos As Integer
     Dim Locale As Long
     
     Locale = GetUserDefaultLCID()

'LOCALE_SDATE is the constant for the date separator
'as stated in declarations
'for any other locale setting just change the constant

'Function can also be re-written to take the
'locale symbol being requested as a parameter
     
     iRet1 = GetLocaleInfo(Locale, RSValue, _
     lpLCDataVar, 0)
     Symbol = String$(iRet1, 0)
     
     iRet2 = GetLocaleInfo(Locale, RSValue, Symbol, iRet1)
     Pos = InStr(Symbol, Chr$(0))
     If Pos > 0 Then
          Symbol = Left$(Symbol, Pos - 1)
          Get_locale = "Regional Setting = " + Symbol
     End If

End Function

Public Function Set_locale(RSValue As LOCAL_INFO) 'Change the regional setting

     Dim Symbol As String
     Dim iRet As Long
     Dim Locale As Long
     
'LOCALE_SDATE is the constant for the date separator
'as stated in declarations
'for any other locale setting just change the constant

'Function can also be re-written to take the
'locale information being set as a parameter

     Locale = GetUserDefaultLCID() 'Get user Locale ID
     Symbol = "-" 'New character for the locale
     iRet = SetLocaleInfo(Locale, RSValue, Symbol)
   
End Function

'****** end of bas file ******************

0
Industry Leaders: 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!

 
LVL 70

Expert Comment

by:Éric Moreau
ID: 6985017
please maintain

Questions Asked 12
Last 10 Grades Given B A A A A  
Question Grading Record 5 Answers Graded / 5 Answers Received
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 7060650
This question appears to be abandoned. A question regarding it will be left in the Community Support
area; if you have any comment about the question, please leave it here.

Unless there is objection or further activity, one of the moderators will be asked to accept the comment
of <hongjun >.

The link to the Community Support area is:
http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt

DO NOT ACCEPT THIS COMMENT AS AN ANSWER.
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 7061027
Just for clarification since my english is ugly than my code:
Question is regarding language support for tooltips not custom one, isn't it?
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 7061684
The title and the text are saying different things!

I think it should be fair to splits points between <hongjun> (for the title) and <Richie_Simonetti> (for the text).
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 7063831
That's good to me.
0
 
LVL 1

Expert Comment

by:Moondancer
ID: 7065791
Thanks for your help.

Points split ...
Points for Richie_Simonetti -> http://www.experts-exchange.com/jsp/qShow.jsp?qid=20309564

ATTENTION bhatul -->  Please click the following link and BRING ALL YOUR OPEN QUESTIONS TO A CONCLUSION.  Administration will be contacting you in this regard if they remain open for another 7 days.  You have nine (9) questions to resolve.

http://www.experts-exchange.com/jsp/memberProfile.jsp?mbr=bhatul&showQHistory=true

Moondancer - EE Moderator

0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

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

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Ever visit a website where you spotted a really cool looking Font, yet couldn't figure out which font family it belonged to, or how to get a copy of it for your own use? This article explains the process of doing exactly that, as well as showing how…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

636 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