Home

Highlight a cell

%3CLINGO-SUB%20id%3D%22lingo-sub-135722%22%20slang%3D%22en-US%22%3EHighlight%20a%20cell%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-135722%22%20slang%3D%22en-US%22%3E%3CP%3EGreetings%20all%2C%26nbsp%3B%26nbsp%3B%3C%2FP%3E%0A%3CP%3EA%20complete%20ignoramus%26nbsp%3Bhere!%20Please%2C%20can%20anyone%20advise%3F%3C%2FP%3E%0A%3CP%3EThe%20situation%20is%20this%2C%20I%20am%20working%20on%20a%20MacBook%2013%22%20with%20Microsoft%20Office%202016.%20I%20have%20just%20taken%20over%20as%20treasurer%20of%20our%20little%20club.%20I%20have%20a%20workbook%20of%20just%20six%20pages%20with%20names%20scattered%20all%20over%20them.%26nbsp%3B%3C%2FP%3E%0A%3CP%3EI%20want%20to%20find%20all%20the%20occurrences%20of%20the%20name%20%22Smith%22%20so%20I%20put%20it%20in%20the%20search%20box%20and%20no%20problems%20EXCEPT%20it%20is%20so%20hard%20to%20see!%3C%2FP%3E%0A%3CP%3EI%20have%20found%20a%20macro%20which%20turns%20the%20cell%20yellow%20when%20it%20is%20active%20which%20is%20really%20helpful.%20Please%20see%20below.%3C%2FP%3E%0A%3CP%3ESub%20Workbook_SheetSelectionChange(ByVal%20Sh%26nbsp%3BAs%20Object%2C%26nbsp%3BByVal%20Target%26nbsp%3BAs%20Excel.Range)%3C%2FP%3E%0A%3CP%3E'Update%2020140923%3C%2FP%3E%0A%3CP%3EStatic%20xLastRng%26nbsp%3BAs%20Range%3C%2FP%3E%0A%3CP%3EOn%20Error%20Resume%20Next%3C%2FP%3E%0A%3CP%3ETarget.Interior.ColorIndex%20%3D%206%3C%2FP%3E%0A%3CP%3ExLastRng.Interior.ColorIndex%20%3D%20xlColorIndexNone%3C%2FP%3E%0A%3CP%3ESet%20xLastRng%20%3D%20Target%3C%2FP%3E%0A%3CP%3EEnd%20Sub%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EBut%20I%20cannot%20save%20it!%26nbsp%3B%20It%20keeps%20asking%20me%20to%20save%20in%20a%20different%20format%20which%20I%20do%20but%20still%20no%20joy.%3C%2FP%3E%0A%3CP%3EPlease%2C%20could%20someone%20clever%20enough%20to%20know%20the%26nbsp%3Banswer%20and%20also%20clever%20enough%20to%20explain%20it%20in%20layman's%26nbsp%3B%20term.let%20me%20know%3F%3C%2FP%3E%0A%3CP%3EIf%20you%20can%20a%20donation%20to%20a%20charity%20will%20be%20made.%26nbsp%3B%20Mike%20T%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-135722%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EMacros%20%26amp%3B%20VBA%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ENeed%20Help%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-135736%22%20slang%3D%22en-US%22%3ERe%3A%20Highlight%20a%20cell%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-135736%22%20slang%3D%22en-US%22%3E%3CP%3EIf%20you%20want%20to%20save%20a%20workbook%20contains%20macros%2C%20then%20you%20have%20to%20%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F968197%2Fsave-a-file-in-a-different-format-in-microsoft-office-for-mac-applicat%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Esave%3C%2FA%3E%20it%20in%20one%20of%20these%20formats%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3EExcel%20Macro-Enabled%20Workbook%20(.xlsm)%3C%2FLI%3E%0A%3CLI%3EExcel%20Binary%20Workbook%20(.xlsb)%3C%2FLI%3E%0A%3CLI%3EExcel%2097-2004%20Workbook%20(.xls)%3C%2FLI%3E%0A%3CLI%3EExcel%205.0%2F95%20Workbook%20(.xls)%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EI%20recommend%20you%20to%20use%20the%20first%20one.%3C%2FP%3E%3C%2FLINGO-BODY%3E
Mike Tagg
Occasional Visitor

Greetings all,  

A complete ignoramus here! Please, can anyone advise?

The situation is this, I am working on a MacBook 13" with Microsoft Office 2016. I have just taken over as treasurer of our little club. I have a workbook of just six pages with names scattered all over them. 

I want to find all the occurrences of the name "Smith" so I put it in the search box and no problems EXCEPT it is so hard to see!

I have found a macro which turns the cell yellow when it is active which is really helpful. Please see below.

Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Excel.Range)

'Update 20140923

Static xLastRng As Range

On Error Resume Next

Target.Interior.ColorIndex = 6

xLastRng.Interior.ColorIndex = xlColorIndexNone

Set xLastRng = Target

End Sub

 

 

But I cannot save it!  It keeps asking me to save in a different format which I do but still no joy.

Please, could someone clever enough to know the answer and also clever enough to explain it in layman's  term.let me know?

If you can a donation to a charity will be made.  Mike T

  

1 Reply
Highlighted

If you want to save a workbook contains macros, then you have to save it in one of these formats:

  • Excel Macro-Enabled Workbook (.xlsm)
  • Excel Binary Workbook (.xlsb)
  • Excel 97-2004 Workbook (.xls)
  • Excel 5.0/95 Workbook (.xls)

 

I recommend you to use the first one.

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
46 Replies
Extentions Synchronization
Deleted in Discussions on
3 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
30 Replies
flashing a white screen while open new tab
Deleted in Discussions on
14 Replies
Security Community Webinars
Valon_Kolica in Security, Privacy & Compliance on
13 Replies