Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    Visual Basic




How To Change The Font Type And Font Size For A Menu Bar?


Dear all, I meet a problem in my application. How can i change the font type and font size for the menu used in th form? Since my application is run on 1280x1024, it is too small to see the type on the menu bar. Could anyone help me? Very urgent!!! Thanks.Paul




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Change The Font Size Of The Menu
Hi All,
How can we change the font size of the menu?
TIA,
kalpana

Change Pop Up Menu Font And Size
How do i change the font and size of
popup menu in Visual Basic

Change Menu Font And Size
How do i change the font and size of menu which , I create
through menu editor in Visual Basic

Change Font Type & Size In RichTextBox??
How do I change FontName and Font Size in a RichTextBox1 using two ComboBox... ComboBox1 for Font Name, and ComoBox2 for Font Size....Thnx

How To Change The Font Type And Size In Vb Program
Hi,

How can I change the font type and size of a word file in Vb program.

Thanks

James

Change Font N Size In Popup Menu
hi folks
am creating one popupmenu using createpopupmenu() API
and also i insert items dynamically using insertmenuitem API
and display using Trackpopupmenu().
My problem is

1)i want to change the background color of popup menu?????
2)Question is i want to change the font size in popup menu ???????
dynamically .
if any body know API or how to change the font size and change the background color in popupmenu ,please help ur friend.

Important:
I don't need menu editor.
i need only popup menu.
expecting a positve reply.
-------------------------------------------------
"HARD WORK NEVER END FAILS"
-------------------------------------------------

How To Change The Font Size Of Menu Items?
I know we may call SetWindowLong to set up a callback function to handle the font size of menu items. But I wander if there is any easier way to achieve that? Thanks for your inputs.

How To Change The Font Size Of Menu Items And Tooltiptext?
I mean how to do that programmatically without changing any settings. Thank you very much!

Font Type & Font Size
Hi,

I was wondering what font type and font size you usually use in your vb projects.
What font size is too small, and what size is too big?
Do you use different fonts in your project? or maybe different font sizes?

As you noticed my question is some kind of a poll, I hope there will be much replies.

Thank you for your time!

OsMo

Printer Font Size Vs Picturebox/form/font Size
HI Everibody.
Sorry for my bad English

Why the printer object font size is different as in Picturebox or form font size property?

I copyied in a PictureBox all the properties availabe in the printer object (width, height, scalemode, scalewidth, etc, etc) to simulate a printer object, but the font size in the picturebox is always greater therefore printer.currentX & Y does not match picture1.currentX & Y

Now, how can I configure a picturebox that matches perfectly the printer proportion? I need it to make Preview routine

How can I caculate the correct scale for Picture1?

Detecting The Current Font And Font Size On Various Lines In A Rich Text Box.
I have written an editor that uses a rich text box as the main text area.

The editor allows the user to select a font and font size on the toolbar.

My question is, how does one get the combo box text (for both the font and font size) to display the font or font size for the current line of the current character location?

Meaning, if I were to type in two lines, the first line being Arial 12pt, and the second line being Tahoma 14pt, how would I get the program to display the font and font size in the combo boxes?

I know about SelFont, SelStart and such, but I am not selecting any text. I am merely moving the cursor up or down and need to be able to display the font and font size for where the cursor currently is.

Anyone have any ideas?

I thank you in advance.

Same Line Different Font Type And Size
hi....

i'm trying to insert a line of text into words with differnt font type &
size.

for example the line below :-

My Name..................123456

'my name' will have font size 7, and '123456' will be size 10 and bold.

I would also like fill the gap between 'my name' and '123456' with '.......'
How do I estimate the number of '.' to fill?

please help me out.....I'm trying to do a directory program for my friend.
Thanks a lot....

Menu's Font And Size
Hi

Can anybody tell me How can I change the font and size of Menu Display items.

Thanks
Jaggu

Detecting Font And Font Size On Various Lines In A Rich Text Box.
I have written a basic editor that uses fonts and such, however when I select a different line (while entering text into the text area of the rich text box), it doesn't display the font or font size for that particular location.

Does anyone have any ideas where I can look to solve this problem?


I thank you in advance for any information you may be able to share with me.

Change Font Size In RTB, But Not All Of It!
I have the code below to change the size of the selected font in a RichTextBox.

If the user selects a different size font part way through using the RTB, how do I get the text from that point on to be the newly selected size?
I have a combobox with the sizes available for the font.


Code:
Private Sub cmbFontSize_Click()
On Error GoTo ErrTrap

If Len(rtbNotes.SelText) > 0 Then
rtbNotes.SelFontSize = cmbFontSize.List(cmbFontSize.ListIndex)
rtbNotes.SetFocus
Else
''rtbNotes.SelFontSize = cmbFontSize.List(cmbFontSize.ListIndex)
End If

Exit Sub

Change Font Size
Is it possible to change the font or font size of the VB IDE?

I.e. I want to lower the font size of the code editor so I can see more code on my screen at once. Hopefully, without changing my screen resolution.

TIA.

Tristan Wolf

Confucious say, "Man who fight salmon should use right hook."

Popupmenu Background Color Change As Well As Font Size Change
hi folks
am creating one popupmenu using createpopupmenu() API
and also i insert items dynamically using insertmenuitem API
and display using Trackpopupmenu().
My problem is

1)i want to change the background color of popup menu?????
2 i want to change the font size in popup menu ???????
dynamically .
if any body know API or how to change the font size and change the background color in popupmenu ,please help ur friend.

Important:
I don't need menu editor.
i need only popup menu.
expecting a positve reply.
-------------------------------------------------
"HARD WORK NEVER END FAILS"
-------------------------------------------------

PullDown Menu's Font Size
Does anyone know to change the font size of a pulldown menu create by the Menu Editor in VB?

Want To Increase Font Size In Menu Bar
Is there a way to increase the font size in the menu bar of
applications built using VB6?

TIA - Bryan

How To Get The Font Name And Font Size Of Header/footer Text?
Hi Everybody

Simple question.

In one of my procedures, I write the VBA Excel code set the text for headers and footer specifying the font name and font size (code line shown below in part).


Code:
'...
'...
'worksheetName has been previously defined to contain the
'name of the worksheet being handled
fullFilename = ActiveWorkbook.FullName
footerText = fullFilename & "[" & worksheetName & "]"
With ActiveSheet.PageSetup
.LeftFooter = "&""Times New Roman,Regular""&06" & footerText
End With
'...
'...


However, when I try to read the same (header/footer text) using code and assign it to a string variable, it actually includes the VBA code referring to the font name and font size as well. This is what I get (the contents of the string variable is shown below).

&"Times New Roman,Regular"&06H:MSOFFICEMY DOCUMENTSCombined National Monthly ReportTest11.xls[SBU - East]

Have a look at all the text prior to "H:..."

But when you see the header/footer content in pagesetup -> headers/footers, you only see the actual text viz :-

"H:MSOFFICEMY DOCUMENTSCombined National Monthly ReportTest11.xls[SBU - East]"


Is there a way to read this actual text only in to a string variable?


Best regards


Deepak Agarwal

Retain Font Styles When Changing Font Size
March 25, 2008

Re: VB6

Hello, everyone. I searched for over two hours for an answer but didn't find a relevant forum example. I am using a richtextbox for my documentation. I made several simple font features such as font sizes and font styles (bold and underline) to the richtextbox. The problem I have is that after I bolded and underlined some of my document text, if I change my document to a different font size, any text that have been bolded or underlined will be undone, so I have to highlight them and bold or underline them again. Does anyone have any advice or any example code to correct it?

The following is a fragment of code in selecting for fontbold and for changing font size:

If Len(Trim(RichTextBox1.SelText)) > 0 Then' For selecting text
RichTextBox1.SelFontSize = 14
End If
RichTextBox1.SelBold = Not (RichTextBox1.SelBold)' For selecting text for bold
RichTextBox1.Font.Size = 14 ' Font size to the whole document or richtextbox

Any advice or help will be greatly appreciated.

Mydanvue

How To Change Font And Size On Runtime
Hello, im making an application that needs the ability to be resized according to the user's screen (640x480, 1042x768, etc) or whenever the user wants to. What is the best way to implement it? Different forms? Anyone has done something to accomodate a form when the fonts are changed? Thanks..

Change Font Size In A RichTextBox
Is there a simple command to change the font size of all the text in a RichTextBox. The only method that I have found so far is

RichTextBox1.SelStart = 0
RichTextBox1.SelLength = Len(RichTextBox1)
RichTextBox1.SelFontSize = 14
RichTextBox1.SelStart = 0

It works but highlights all the text first, then changes the font size and finally restores the cursor to the start of the text.

RichTextBox1.Font.Size = 14 only changes the first bit of text.

To Change Font Size Of The Titlebar
Hello,

I've changed the Font of the title bar of the form through "systemparametersinfo" parameters. n now i want to change the font size.


But in the case of multilingual fonts the display changes coz the font size is different for different languages.

can u help me to change the font size of the title bar?????
the code to change the font of the title bar as follows :





Private Type LOGFONT
lfHeight As Long
lfWidth As Long
lfEscapement As Long
lfOrientation As Long
lfWeight As Long
lfItalic As Byte
lfUnderline As Byte
lfStrikeOut As Byte
lfCharSet As Byte
lfOutPrecision As Byte
lfClipPrecision As Byte
lfQuality As Byte
lfPitchAndFamily As Byte
lfFaceName(1 To 32) As Byte
End Type


Private Type NONCLIENTMETRICS
cbSize As Long
iBorderWidth As Long
iScrollWidth As Long
iScrollHeight As Long
iCaptionWidth As Long
iCaptionHeight As Long
lfCaptionFont As LOGFONT
iSMCaptionWidth As Long
iSMCaptionHeight As Long
lfSMCaptionFont As LOGFONT
iMenuWidth As Long
iMenuHeight As Long
lfMenuFont As LOGFONT
lfStatusFont As LOGFONT
lfMessageFont As LOGFONT
End Type

Private Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, lpvParam As NONCLIENTMETRICS, ByVal fuWinIni As Long) As Long
Private Declare Function CreateFontIndirect Lib "gdi32" Alias "CreateFontIndirectA" (lf As LOGFONT) As Long

Dim ncm As NONCLIENTMETRICS 'NONCLIENTMETRICS to change
Dim Orincm As NONCLIENTMETRICS 'NONCLIENTMETRICS to replace original
Dim Returned As Long
Dim lf As LOGFONT
Dim hFont As Long


Private Sub Combo1_Click()

Dim i As Integer
ncm.cbSize = Len(ncm)

Returned = SystemParametersInfo(41, 0, ncm, 0) 'get the system NONCLIENTMETRICS
Orincm = ncm 'store the value of system NONCLIENTMETRICS to use later
'now to change the font name
'other functions can be used to change t
' he font name
'but for simplicity i have used asc() &
' mid()


For i = 1 To Len(Combo1.Text) 'use ncm.lfMenuFont.lfFacename(i) to change menu font
ncm.lfMessageFont.lfFaceName(i) = Asc(Mid(Combo1.Text, i, 1))
ncm.lfCaptionFont.lfFaceName(i) = Asc(Mid(Combo1.Text, i, 1))
Next i
ncm.lfMessageFont.lfFaceName(i) = 0 'add null at the end of font name
ncm.lfCaptionFont.lfFaceName(i) = 0
Returned = SystemParametersInfo(42, 0, ncm, &H1 Or &H2) 'remove &H2 if you don't want to affect all the open windows

lf.lfHeight = 24 ' character height in pixels
lf.lfWidth = 12 ' character width in pixels
lf.lfEscapement = 0 ' orientation of next character
lf.lfOrientation = 0 ' orientation of first character
lf.lfWeight = 400 ' normal thickness
lf.lfItalic = False ' not italic characters
lf.lfUnderline = True ' not underlined characters
lf.lfStrikeOut = False ' not strikeout characters
lf.lfCharSet = 255 ' OEM character set
lf.lfOutPrecision = 0 ' default output precision
lf.lfClipPrecision = 0 ' default clipping precision
lf.lfQuality = 0 ' default scaling quality
lf.lfPitchAndFamily = 64 ' default pitch, script font family

hFont = CreateFontIndirect(lf)
MsgBox hFont
MsgBox "Message & Caption Font Changed to " & Combo1.Text, vbOKOnly, "Amit"
' Returned = SystemParametersInfo(42, 0, Orincm, &H1 Or &H2) 'replace original font
' MsgBox "Message & Caption Font Replaced to " & StrConv(Orincm.lfCaptionFont.lfFaceName, vbUnicode), vbOKOnly, "Amit"


'
End Sub



Private Sub Form_Load()

' Heres a very simple code to change the
' system
' NONCLIENTMETRICS like the the window t
' itle font,
' the message font,menu font using VB. Y
' ou can also change
' other elements like status font etc
' in your window only or all the open wi
' ndows
' like PLUS! or display settings (appear
' ance)
' also it is possible to underline, stri
' kethru fonts in
' your window with this code. This code
' is very useful
' if you are coding a multi-lingual soft
' ware.
' For more info and more free code send
' e-mail.
'
' email - vengs_amit@yahoo.com

Dim i As Integer
Show
' to flood the combo box with first 10 f
' onts


For i = 1 To 200 ' or use For i = 1 To Screen.FontCount to flood all the fonts in your pc
Combo1.AddItem Screen.Fonts(i)
Next i
End Sub

Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
Returned = SystemParametersInfo(42, 0, Orincm, &H1 Or &H2) 'replace original font
MsgBox "Message & Caption Font Replaced to " & StrConv(Orincm.lfCaptionFont.lfFaceName, vbUnicode), vbOKOnly, "Amit"

End Sub

Private Sub mnuExit_Click()
Returned = SystemParametersInfo(42, 0, Orincm, &H1 Or &H2) 'replace original font
MsgBox "Message & Caption Font Replaced to " & StrConv(Orincm.lfCaptionFont.lfFaceName, vbUnicode), vbOKOnly, "Amit"
End

End Sub

Change Size Font In Flexgrid
Hi

How can I to change size font from flexgrid, via Code ?

Please post a example


tks

Help Me To Change The Font Size Of My POS Printer
Hello forum,
I have a TP-100 dotmatix pos printer and I'm curruntly print receipt using printer.print method. But when I try to change the font size using printer.fontsize, there is no effect on the print outs. I want to use different sizes of fonts in my POS printer. Is there any way I can do this without using Printer.FontSize.

I also want to know how to display line of text on a Pole Display. If theres anyone to help me that will be a great help. Thank You!

How Do I Change The Font Size In A RtfText Box?
I give the user a common font dialog and get the font name and size from them, I can then change the font but how do I change the font size?
Here is my code so far:
On Error Resume Next
CommonDialog1.CancelError = True
cdlFont.FontName = rtfText.Font
cdlFont.FontSize = rtfText.Font
cdlFont.FLAGS = cdlCFBoth
cdlFont.ShowFont
If Err.Number = cdlCancel Then
Err.Clear
Exit Sub
Else
rtfText.Font = cdlFont.FontName
End If

Change The Font Size Of The Msgbox
could someone tell me how to change the font size of the msgbox, please.

/CC.

How To Change The Font Size Of Tooltip?
Say, I have a couple of buttons in a form. When mouse moves on the buttons, the tooltip will be shown. Now the font size of tooltips is considered too small. Is there any easy way to change it? Thanks for your inputs.

Change Font Size At Run Time
In VB, how can you change the font size in a picture box dynamically if the scale properties (I mean coordintates) are changed? In other words, how can the font size be increased or decreased in proportion to the scale properties?

Thanks in advance.

Change Font Size Dynamically
In VB, how can you change the font size in a picture box dynamically if the scale properties (I mean coordintates) are changed? In other words, how can the font size be increased or decreased in proportion to the scale properties?

Thanks in advance.

Change Font Type In VB?
On my sheet I've created I need to create different font types (mostly BOLD) for use in title sections.

What is the code in VB to do this?

I need to format individual cells, and maybe a row.

Thanks in advance.

Subclassing A Combobox To Change The Font Size
I've been working on a problem that I describe in this thread and have come to the conclusion that the solution will probably require subclassing the combobox.

What I would like to end up with is something that looks like this when dropped down:


Code:
Topic 1
Item 1
Item 2
Item 3
...
Topic 2
...
I've taken a look at the examples in the code library and tutors corner about subclassing and, while I'm still new at it, I get the concept at least.

I have two questions about the subject however. First, what API would I be using to set the font size and weight (how bold it is)? CreateFont?

Second, and probably more importantly, what steps would be involved in drawing the text to the combobox? For instance, would I have to do something to the rectangle that holds each entry in the combobox and, if so, could someone point me in the right direction?

Thanks for your help.

How To Print In Dos Mode And How To Change Font Size ?
I wish to dos mode printing to print bills, (Creating Text file to print). How can i change font size ?

I saw following codes in sample for printing dos mode. Please explain usage of following codes

Print #1, Chr(27) 'purpose ?
Print #1, Chr(12) 'purpose ?
Print #1, particulars; Spc(17 - Len(CStr(particulars))); ' purpose ?
Print #1, vbCr ?

How can i set paper size ?


Senthil kumar.A

Change Output Text's Font Size
hi all,

i have a problem here.actually im developing a Normalization Tool using Vb 6.0. the main function of this tool is user can draw ERD using drawing toolbar and then this tool will help to narmalized it.for sure,user must input attributes for each entity when drawing ERD.

the entity's name and attribute's name will be appear on the notation of Entity.is it possible if i wan to change the font size of attribute's name?and can give any ideas to do it?

thanks a lots..

Change Font Size Of MSChart 1 Values???
hi! i want to know how to change the font size of the values of both the x and y axis of MSChart1 control. I want to make my font smaller because the numbers are too big and they are not readable.

I hope somebody can help me.

Thank you so much!

I Should Know This But, How Do You Change The Default Font Size For A Project?
Hi,
How do you change the default font size for a project?

I've been setting the font property for every text box, frame, label, command button, etc. There's got to be an easier way.

Thanks,
Al.

How Do I Change Font Size When Outputting To Word Pad
How do I change font size when outputting to Word Pad or just a txt file?

thank you

How To Change Font Size On A Single Line
I am using Vb6's standard print object and would like to know how to change the font size in a line of print.

I need to print "123 Welcome 123", on the first line of a page and would like the "123's" to be in a different font size than the "Welcome"

I have experimented with things like

printer.font.size = 20
printer.print Tab(2);"123";font.size=12; Tab(18);"Welcome"; font.size=20; Tab(40); "123"
printer.enddoc

The result is: 123False WelecomeFalse 123 all at size=20, but properly tabed.

I have looked at using the richtextbox also but the code for a WYSISWYG does not appear to be a simple undertaking.

How To Change The Font Size Of The Caption Of A Form?
Actually, I tried to change the font property of the form, but it doesn't change the font size of the caption. Any ideas how to do that? Thanks for your inputs.

How To Change Font Type Of Word Doc?
I am opening up a word doc and pasting the clip board content to the Word.Document object.
By default it is taking Times New Roman 12 font.....
how can i change this to different font type....
I am pasting the contents programatically...

Change The Font Of Menu In VB
Hello
How can we change the font of Menu in VB

I want to change the from from English to Urdu (Language spaks in Pakistan like Arabic Language with some additions.)

Please help me

How I Can Change The Font Of Menu
how i can change the font of Menu

Change Menu Font
Hi All,
Any one help me, how to change the "menu" font through code.

How Do I Change The Menu Font
Hi!

Do u know how i can change the fontname of a menu.

/thanx

Change The Font Of A Menu
Hi, to all
can any one help, I need to change the font for a menu items that is created using menu editor of vb6
thanks
fawzy

Change Menu Font
When using the Pull Down Menu from Visual Basic 6.0 there is no property to resize the font size of the pull down menus. Our programs' main midi form starts in normal mode and everything including the pull down menus are in proportion. We have a routine when the user wants to goto max screen, which resizes all forms and controls proportionaly so everthing looks proper in the full screen mode. However the pull down menu's font is still small and thus is out of proportion. It is very irritating and defeats the whole purpose of going to a full screen mode for easier viewing. There is no property to change this in the menu editor I can find. I believe it is using a system font and that is why you can't change it. Is there a work aorund for this, something we can change when in this mode and put back to normal when we exit?
 
Thank you
bulwelling
Software Reality

Change In Font Of Menu
Hi Gurus,
I want to change the font of the Menu. More specific .. I want to display menu in other langauge like hindi/marathi
I can change fornt of caption of other control or even whatever I am printing on form that get's displayed in other langauge.
Thanks in Advance

Regards
Satish

Changing Font Size And Bold And Font ???
dim Heading as string
Heading = "I want to Make this sentance Bold and bigger"

how would i go about making this variable bold and changing the font and font size.
thankyou

Copyright © 2005-08 www.BigResource.com, All rights reserved