Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
roger_home
 
Posts: n/a
Default How do I put this macro on a EXCEL sheet?


I want to put this macro on a file...it is suppose to make a cell a
check box...where do I put it?

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Application.EnableEvents = False
On Error GoTo sub_exit
If Not Intersect(Target, Range("A1")) Is Nothing Then
With Target
If .Value = "ü" Then
.Value = ""
Else
.Value = "ü"
.Font.Name = "Wingdings"
End If
End With
End If
sub_exit:
Application.EnableEvents = True
End Sub


--
roger_home
------------------------------------------------------------------------
roger_home's Profile: http://www.excelforum.com/member.php...o&userid=16434
View this thread: http://www.excelforum.com/showthread...hreadid=516046

  #2   Report Post  
Posted to microsoft.public.excel.misc
wdjsxj
 
Posts: n/a
Default How do I put this macro on a EXCEL sheet?

view/toolbars/activex select checkbox and click on the sheet
right click the checkbox select code
roger_home编写:


I want to put this macro on a file...it is suppose to make a cell a
check box...where do I put it?

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Application.EnableEvents = False
On Error GoTo sub_exit
If Not Intersect(Target, Range("A1")) Is Nothing Then
With Target
If .Value = "ü" Then
.Value = ""
Else
.Value = "ü"
.Font.Name = "Wingdings"
End If
End With
End If
sub_exit:
Application.EnableEvents = True
End Sub


--
roger_home
------------------------------------------------------------------------
roger_home's Profile: http://www.excelforum.com/member.php...o&userid=16434
View this thread: http://www.excelforum.com/showthread...hreadid=516046


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
Combining data from cells from several excel sheets to a new sheet Rik Excel Discussion (Misc queries) 4 February 22nd 06 09:16 AM
Data Range Mess Karen Charts and Charting in Excel 18 January 14th 06 02:34 PM
checking that cells have a value before the workbook will close kcdonaldson Excel Worksheet Functions 8 December 5th 05 04:57 PM
Excel Macro to Copy & Paste [email protected] Excel Worksheet Functions 0 December 1st 05 01:56 PM
create a macro to save excel sheet Moussa Hawas Excel Worksheet Functions 1 October 16th 05 09:19 PM


All times are GMT +1. The time now is 03:14 AM.

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

About Us

"It's about Microsoft Excel"