Solved

Hiding formula VBA

Posted on 2014-10-27
6
111 Views
Last Modified: 2014-10-27
Hi,

I need some vba code to hide the formulas in a range of cells "A18:W118"

I have tried to protect the range using locked/hidden and then protect sheet, however my slicers stop working then

Is there a VB solution?

Many thanks
Seamus
0
Comment
Question by:Seamus2626
6 Comments
 
LVL 2

Expert Comment

by:Glen Richmond
ID: 40406064
could always hide the formula bar?
0
 
LVL 25

Accepted Solution

by:
ProfessorJimJam earned 250 total points
ID: 40406074
Seamus2626

do the followings

select range "A18:W118"  and then right click then go to cell formatting then select custom formatting and then type three times semicolon ;;;  and then click ok.  then go to view tab and un-mark the formula bar.
0
 
LVL 2

Expert Comment

by:Glen Richmond
ID: 40406082
Ofcourse use the VBA recorder to capture the method suggested by ProfessorJimJam to include into VBA.
0
Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

 
LVL 85

Expert Comment

by:Rory Archibald
ID: 40406105
If you just want to hide those formulas, you have to set the Hidden property and protect the sheet. You haven't indicated what the slicers are used for, or where they are.
0
 
LVL 10

Assisted Solution

by:GasperK
GasperK earned 250 total points
ID: 40406131
You should do exactly what you did but in the protect Sheet also select the Edit Objects and Use PivotTable & PivotChart...
You will have the formulas hidden and also, your Slicers will work.
Protect Sheet options
0
 

Author Closing Comment

by:Seamus2626
ID: 40406199
Thanks guys
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Drop Down List with Unique/Distinct Values (Part II - ComboBox or ListBox and Data Validation List Bonus!) David Miller (dlmille) Intro This article focuses on delivering unique, sorted lists to list objects (e.g., ComboBox, ListBox) and Dat…
How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now