473,799 Members | 3,197 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Msgbox text font

Hi. I have Access 2003 and I am finding that the font in the text
displayed in Msgbox displays it too small. Is there anyway to increase
the font size of that text?

Regards,
SueB

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #1
14 25455
Susan,
No, not without changing the OS desktop operating system appearance
settings.

A couple of suggestions;

1) Use uppercase bold characters. The bold switch is two @ signs
separated by a space at the end of the string, like this;

Msgbox UCase("This is my big bold message @ @")

-or-

2) Create a form that looks like a message box. That will give you
more control over the fonts in whatever text boxes you use. Make it
popup, modal, change the border style and remove the close box.

HTH.

Nov 13 '05 #2
Great ideas. Thanks.

Regards,
SueB

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #3
"Susan Bricker" wrote
Great ideas. Thanks.


Another alternative is to create your own Form to use instead of the
standard MsgBox, so that you have control over these factors. That is often
done if you want the modal form to close itself after some period of time --
there's no MsgBox argument for that, but you can create a Form with a Timer
and Do It Yourself.

Larry Linson
Microsoft Access MVP
Nov 13 '05 #4
Lyn
"Wolf" <sp************ *@hotmail.com> wrote in message
news:11******** *************@g 47g2000cwa.goog legroups.com...
Susan,
No, not without changing the OS desktop operating system appearance
settings.

A couple of suggestions;

1) Use uppercase bold characters. The bold switch is two @ signs
separated by a space at the end of the string, like this;

Msgbox UCase("This is my big bold message @ @")

-or-

2) Create a form that looks like a message box. That will give you
more control over the fonts in whatever text boxes you use. Make it
popup, modal, change the border style and remove the close box.

HTH.


I hadn't heard of the "@ @" trick, so I tried it and it didn't work (A2003).

MsgBox Ucase("My message @ @")

resulted in a non-bold display of:

MY MESSAGE @ @

Am I missing something? (I used the immediate window if that is
significant.)

--
Cheers,
Lyn.
Nov 13 '05 #5
Susan Bricker wrote:
Hi. I have Access 2003 and I am finding that the font in the text
displayed in Msgbox displays it too small. Is there anyway to increase
the font size of that text?

Regards,
SueB

*** Sent via Developersdex http://www.developersdex.com ***


Print Programming in Windows
Jeff Potts
R & D Books, Miller Freeman, Inc.
Lawrence, Kansas 66046
Copyright 2000
ISBN 0-87930-585-1

contains some very interesting ideas about using Windows API functions
to play with fonts. The handle to a window, to a Device Context and to
a font all seem to have wondrous possibilities. I became interested in
these techniques with the hopes of jazzing up the fonts in Access
reports since a user was complaining that she could export a query to
Excel and get the output to look better than an Access report.

An example from the book:
</StartQuote>
Declare Function TextOut Lib "gdi32" Alias "TextOutA" _
(ByVal hdc As Long, ByVal x As Long, ByVal y As Long, _
ByVal lpString As String, ByVal nCount As Long) As Long

There's not much to the routine. Both the x and y parameters specify
the location at which to place the text, the hdc parameter is the
destination device context, lpString is the string of text you want to
print, and cbString holds the number of characters you want to display.
Both the x and y parameters use the measurements specified by
SetMappingMode( ) when positioning the text. Since we are using the
default setting for coordinate mapping (MM_TEXT), everything will be
measured in device pixels. As with most API routines, a nonzero
indicates a successful call and a zero (or false) indicates some sort
of error. The most common error that could occur when calling this
routine is passing the function an invalid HDC.

....

(Visual Basic)
Sub PrintTextRandom (phdc As Long, hfont As Long, margins As RECT, _
x As Integer, y As Integer, str As String)
Dim oldfont As Long
Dim ret As Long

oldfont = SelectObject(ph dc, hfont)
ret = TextOut(phdc, margins.left + x, margins.top, str, Len(str))
ret = SelectObject(ph dc, oldfont)
End Sub

As you can see, this function is fairly simple. Basically, I select
the font into the HDC, print the text using TextOut(), and put the
previous font handle back into the HDC. With extensive printing of
text, this method of selecting of the font in-and-out of the HDC coud
degrade performance. On the other hand, it acts as a safeguard against
selecting an object into an HDC and forgetting to put it back. As
we've discussed previously, this is the fast-track to losing system
resources.
</EndQuote>

James A. Fortune

Nov 13 '05 #6
@ @ stopped working somewhere around Access 2000.

It still works in the hidden and undocumented wizmsgbox procedure:

Public Sub blahblah()
With WizHook
.Key = 51488399
.WizMsgBox "Bold Line @ @ Not So Bold Line", _
"The Caption", vbYesNo, 23, "Path To Some Help File"
End With
End Sub

(tested in Access 2002).

Nov 13 '05 #7
Lyn
<ly******@yahoo .ca> wrote in message
news:11******** **************@ z14g2000cwz.goo glegroups.com.. .
@ @ stopped working somewhere around Access 2000.

It still works in the hidden and undocumented wizmsgbox procedure:

Public Sub blahblah()
With WizHook
.Key = 51488399
.WizMsgBox "Bold Line @ @ Not So Bold Line", _
"The Caption", vbYesNo, 23, "Path To Some Help File"
End With
End Sub

(tested in Access 2002).

Still works in A2003. Thanks for that, I never knew it existed. Not sure
how/when I would use it either :-)

--
Cheers,
Lyn.
Nov 13 '05 #8

"Lyn" <lh******@iiNet .net.au> wrote in message
news:42******** **************@ per-qv1-newsreader-01.iinet.net.au ...
<ly******@yahoo .ca> wrote in message
news:11******** **************@ z14g2000cwz.goo glegroups.com.. .
@ @ stopped working somewhere around Access 2000.

It still works in the hidden and undocumented wizmsgbox procedure:

Public Sub blahblah()
With WizHook
.Key = 51488399
.WizMsgBox "Bold Line @ @ Not So Bold Line", _
"The Caption", vbYesNo, 23, "Path To Some Help File"
End With
End Sub

(tested in Access 2002).

Still works in A2003. Thanks for that, I never knew it existed. Not sure
how/when I would use it either :-)


There's also what MichKa has at
http://www.trigeminal.com/usenet/usenet015.asp

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)


Nov 13 '05 #9
Douglas J. Steele wrote:
"Lyn" <lh******@iiNet .net.au> wrote in message
news:42******** **************@ per-qv1-newsreader-01.iinet.net.au ...
<ly******@yah oo.ca> wrote in message
news:11****** *************** *@z14g2000cwz.g ooglegroups.com ...
@ @ stopped working somewhere around Access 2000.

It still works in the hidden and undocumented wizmsgbox procedure:

Public Sub blahblah()
With WizHook
.Key = 51488399
.WizMsgBox "Bold Line @ @ Not So Bold Line", _
"The Caption", vbYesNo, 23, "Path To Some Help File"
End With
End Sub

(tested in Access 2002).


Still works in A2003. Thanks for that, I never knew it existed. Not sure
how/when I would use it either :-)

There's also what MichKa has at
http://www.trigeminal.com/usenet/usenet015.asp


And of course, good old Eval("Msgbox("" @@blah"")")

--
[OO=00=OO]
Nov 13 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
1456
by: Marc Jennings | last post by:
Hi, I have a problem with the message text and button text not showing up in a messagebox. (See attachment) The code I used to call this example was > MessageBox.Show(this,"Hello","nothing shown",MessageBoxButtons.OK,MessageBoxIcon.Information); I had this problem a couple of weeks ago when I was running Windows 2003 Server on my dev machine, and I put it down to an OS / Framework
4
2633
by: Arif Çimen | last post by:
Hi to everybody, I have chnged a button text in design mode. But After compiling and executing the program the text of the button do not change to new value. Any Ideas? Thaks for helps.
1
5422
by: CharlieChau | last post by:
How can I change the size to the text in the msgbox in winform. my application does not use the web or vb script. Thanks, /CC.
4
6891
by: | last post by:
I have about 20 MsgBox occurance in by program, which I use to inform the user of the progress of the program, or ask confirmation of an action, or simply to act separators to various parts of the program. They all vary in size and shape depending on the text length. To make the looks of the program more consistant, I made the FIRST and LAST line a series of "======" 65 characters long. Windows displays Message Box text using a...
10
2104
by: Betina Andersen | last post by:
I have inherited a VB.NET dll that I am using from common asp. My problem is to get the messages from the dll to the Ie client, I can see the messages in the Eventlog on the IIS server so I know they are there, but how do I get them to show in IE? The original code was: MsgBox("Kunne ikke finde databasenavn udfra den angivne DSN: " & DSN) I tried to change that to: Result = MessageBox.Show("Kunne ikke finde databasenavn udfra den...
13
31428
by: =?Utf-8?B?S2VzdGZpZWxk?= | last post by:
Hi Our company has a .Net web service that, when called via asp.net web pages across our network works 100%! The problem is that when we try and call the web service from a remote machine, one outside of our domain, we get the error.. ** Client found response content type of 'text/html; charset=Windows-1252', but expected 'text/xml' **. We can discover the web service by typing in the url of the asmx so we know the server can 'see' it...
3
4152
by: MLH | last post by:
Without modifying the default font settings everywhere, is there any way to specify it for just message boxes? MsgBox "I would like this text to be larger for all message boxes." ???
2
1305
by: manikschumi | last post by:
Hello people (VBA related) Some help please. Is there any text formatting that I can do with the text that I want displayed in the MsgBox...bold, a different font and font size is what I am looking for. I have the option of using userforms but I cannot due to certain project restraints. Thanks for the help.
7
3134
by: kirkgilbert | last post by:
I am trying to do an onchange event in a form using a text field. The form is tied to a record set that is part of a repeated region. One the first record when I edit the data it works perfectly. When I go to the second record nothing happens. I have attached the code below: I bolded text that contains the javascript and fields this is applied to <%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%> <!--#include file="Connections/FutureOrders.asp"...
0
9685
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9538
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10470
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10214
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10023
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9067
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7561
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5583
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4135
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.