Solved

Vertical DataBar function in Excel 2003

Posted on 2012-03-09
2
777 Views
Last Modified: 2012-03-09
I use Excel 2003.

I have the following function

Public Function DataBar(lngValue As Long)

DataBar = String(lngValue, ChrW(9608))

End Function

Which I use with the following formula

=IF(S5<0,S5&" "&IF(S5/100<0,DataBar(ABS(S5/100)*0.5),""),"")

to create horizontal Data Bars

Is there anyway to create vertical data bars?
0
Comment
Question by:fitaliano
  • 2
2 Comments
 
LVL 42

Expert Comment

by:dlmille
ID: 37703828
Sure, you just rotate the text alignment of your data bar text by 90 degrees and shift your data to go across a row instead of down a column (if you want it to look like a column chart.

See attached, using my databar function from http://www.mschaef.com/blog/tech/excel/databar.txt

There's nothing wrong with yours, just using mine.  The operation is the same, change orientation of font, then shift your data cells from top down, to left to right.

See attached.

Dave
data-bars-41.xls
0
 
LVL 42

Accepted Solution

by:
dlmille earned 500 total points
ID: 37703836
And here it is using your databar function as well (I used a different formula as the goal here is how to make it all appear vertical and I didn't relate to what data you were using against your databar as you only provided a formula with no sample data - no sample spreadsheet!!)

That's ok - but it helps us help you when you Do do that ;)

Again, its just rotating the text and shifting the data from top down to left to right.

Cheers,

Dave
data-bars-r2.xls
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SIMPLE EXCEL IF STATEMENT THAT JUST WILL NOT WORK 12 42
Access Database 5 47
Modification to nested formula needed 2 25
Excel Pivot Table question 5 16
How to get Spreadsheet Compare 2016 working with the 64 bit version of Office 2016
You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
This Micro Tutorial will demonstrate the scrolling table in Microsoft Excel using the INDEX function.
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

726 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