Excel 7.0 Macro Formula to convert active cell to uppercase 
Author Message
 Excel 7.0 Macro Formula to convert active cell to uppercase

I am VERY new to the Macro world.  I noticed the following in the Excel 7.0
help:

The following macro formula converts the contents of the active cell to
uppercase:
FORMULA(UPPER(ACTIVE.CELL()),ACTIVE.CELL())

How exactly do I use this formula?   If my Worksheet is Sheet 1, what
exactly do I have to write to make this formula work?

Thanks, in advance,
George P. Murphy



Wed, 18 Jun 1902 08:00:00 GMT  
 Excel 7.0 Macro Formula to convert active cell to uppercase

George,
This is an Excel4 type macro.  You would insert an Excel 4 macro sheet and
in column A, row 1 and beyond enter
MakeUpper()
=FORMULA(UPPER(ACTIVE.CELL()),ACTIVE.CELL())
=Return()

If you wanted to execute it as a VBA command you would put it in a vba
module sheet

Sub MakeUpper()
application.ExecuteExcel4Macro _
("FORMULA(UPPER(ACTIVE.CELL()),ACTIVE.CELL())")
End Sub

or if your macro sheet was named Macro1
application.run("Macro1!A1")

In VBA you would use:

ActiveCell.Value = Ucase(ActiveCell.Value)

HTH,
Tom Ogilvy


Quote:
>I am VERY new to the Macro world.  I noticed the following in the Excel 7.0
>help:

>The following macro formula converts the contents of the active cell to
>uppercase:
>FORMULA(UPPER(ACTIVE.CELL()),ACTIVE.CELL())

>How exactly do I use this formula?   If my Worksheet is Sheet 1, what
>exactly do I have to write to make this formula work?

>Thanks, in advance,
>George P. Murphy



Wed, 18 Jun 1902 08:00:00 GMT  
 Excel 7.0 Macro Formula to convert active cell to uppercase

The following VB Code will display whatever is in the selected Cell in
Uppercase, and when you deselect it (select another Cell) it will revert the
content to the original. It also allows data entry in the cell in both upper
and lower case, but will not change it to Uppercase on entry. I haven't
checked it against multiple cell ranges.
Enter the following code in the actual sheet's codepage (Using VB Editor)

Dim CellAddress, EnterContent, ExitContent, Change As String

Private Sub Worksheet_Activate()
    CellAddress = ActiveCell.Address
    LastContent = ActiveCell
    Change = 0
End Sub

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
    Change = 1
End Sub

Private Sub Worksheet_SelectionChange(ByVal Target As Excel.Range)
    ExitContent = Range(CellAddress)
    If Change = 0 Then
        Range(CellAddress) = EnterContent
    End If
    EnterContent = ActiveCell
    ActiveCell = UCase(EnterContent)
    Change = 0
    CellAddress = ActiveCell.Address
End Sub

I don't know if this is what you want to accomplish, but it is kind of
fancy.

Bj?rn

Quote:
-----Original Message-----

Newsgroups:
microsoft.public.excel.misc,microsoft.public.excel.worksheetfunctions
Date: 28. juni 1998 20:39
Subject: Excel 7.0 Macro Formula to convert active cell to uppercase

>I am VERY new to the Macro world.  I noticed the following in the Excel 7.0
>help:

>The following macro formula converts the contents of the active cell to
>uppercase:
>FORMULA(UPPER(ACTIVE.CELL()),ACTIVE.CELL())

>How exactly do I use this formula?   If my Worksheet is Sheet 1, what
>exactly do I have to write to make this formula work?

>Thanks, in advance,
>George P. Murphy



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. converting macros excel 7.0 to excel 97

2. Running macro at active cell in stead of at cell where macro was writen

3. Macro convert from Lotus123r5 to Excel 7.0

4. Overwriting a cell with a formula incorporating the active cell

5. Expressing values of cells realtive to active cell in VBA formula's

6. UPPERCASE -Format one cell to be uppercase

7. Can Excel 7.0 call Word 7.0 Macros?

8. converting cells with formulas in excel 97 to word 97

9. Can Excel 7.0 call Word 7.0 Macros?

10. Copying non-active cell to another non-active cell


 
Powered by phpBB® Forum Software © phpBB Group