Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 74
Default **Increase Font Size for Selected Cell**

Hi,

I want to make one Button to increase the Font Size for the Selected
Cells in worksheet. I made a macro but it increasing the Font only for
"X9" cell.

Can I make one Tougle button for Zoom In and Zoom Out for the Selected
Cell.
if it possible pls help me.

Sub ZOOM()

Range("X9").Select
With Selection.Font
.Name = "Arial"
.Size = 20
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
End With
With Selection.Interior
.ColorIndex = 42
.Pattern = xlSolid
End With
End Sub

Regards

shahzad
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default **Increase Font Size for Selected Cell**

Hi,

Maybe this

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim myrange As Range
Set myrange = UsedRange
myrange.Font.Size = 10
myrange.Interior.ColorIndex = xlNone
Target.Font.Size = 15
Target.Interior.ColorIndex = 42
End Sub

Mike

"Shazi" wrote:

Hi,

I want to make one Button to increase the Font Size for the Selected
Cells in worksheet. I made a macro but it increasing the Font only for
"X9" cell.

Can I make one Tougle button for Zoom In and Zoom Out for the Selected
Cell.
if it possible pls help me.

Sub ZOOM()

Range("X9").Select
With Selection.Font
.Name = "Arial"
.Size = 20
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
End With
With Selection.Interior
.ColorIndex = 42
.Pattern = xlSolid
End With
End Sub

Regards

shahzad

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 74
Default **Increase Font Size for Selected Cell**

On Jul 15, 12:37*pm, Mike H wrote:
Hi,

Maybe this

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim myrange As Range
Set myrange = UsedRange
myrange.Font.Size = 10
myrange.Interior.ColorIndex = xlNone
* * Target.Font.Size = 15
* * Target.Interior.ColorIndex = 42
End Sub

Mike



"Shazi" wrote:
Hi,


I want to make one Button to increase the Font Size for the Selected
Cells in worksheet. I made a macro but it increasing the Font only for
"X9" cell.


Can I make one Tougle button for Zoom In and Zoom Out for the Selected
Cell.
if it possible pls help me.


Sub ZOOM()


* * Range("X9").Select
* * With Selection.Font
* * * * .Name = "Arial"
* * * * .Size = 20
* * * * .Strikethrough = False
* * * * .Superscript = False
* * * * .Subscript = False
* * * * .OutlineFont = False
* * * * .Shadow = False
* * * * .Underline = xlUnderlineStyleNone
* * * * .ColorIndex = xlAutomatic
* * End With
* * With Selection.Interior
* * * * .ColorIndex = 42
* * * * .Pattern = xlSolid
* * End With
End Sub


Regards


shahzad- Hide quoted text -


- Show quoted text -


Hi

Dear Mike, thank you its working nice.

Regards.

Shahzad
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
VBA Function to Increase the Selected Cell Font. Shazi Excel Programming 4 July 13th 08 06:18 PM
Font size and color change for selected cell only Shazi Excel Programming 5 July 11th 08 11:10 PM
Increase font size in a check box Teresa Excel Discussion (Misc queries) 4 December 31st 07 03:26 PM
Number in cell increase with increase in font size. Value increases with increase in font.[_2_] Excel Discussion (Misc queries) 2 August 9th 07 01:58 PM
How do I increase the font size in a cell validation list? Brad Phelps Excel Discussion (Misc queries) 2 August 10th 06 01:00 AM


All times are GMT +1. The time now is 12:04 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"