Hi all
I'm trying to change the format of numbers in a log-scale chart so that they appear as 10^x e.g. 10^3 rather than 1000 or 1E+03 or 1E+3..etc as in this image
http://img135.imageshack.us/img135/7403/picfm9.jpg
http://img135.imageshack.us/img135/p...jpg/1/w847.png
Can you please help how to do this?
Warm thanks
You will need to create you own axis labels and then use code to format them.
Note that Log axis will not allow zero or negative values.
Sub SuperScriptDLabels() Dim objDlabel As DataLabel Dim lngIndex As Long With ActiveChart For lngIndex = 2 To 3 For Each objDlabel In .SeriesCollection(lngIndex).DataLabels With objDlabel .AutoText = False .Text = .Text .Characters(3, 1).Font.Superscript = True End With Next Next End With End Sub
Thank you so much for your help, appreciated
Could you please tell me a little bit about how can I create my own code and formatting the axis, since I'm very new in this stuff.. All I do-usually- is use Excel functions..
Also, when I change the cells location in the attached file, the data points and axis scale change as well, is there a way to control this?
Warm thanks
Well the code should handle most situations so not sure what you want in terms of 'your own code'.
Need more detail on what you mean by cell locations changing.
Do you need help on how to add the 2 extra series and format the axis to not display built-in values?
Open the workbook.
ALT+F11 (opens VBE [Visual Basic Editor])
Insert Module in to project
Paste code into module
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks