Arctangent problem


Dan Tabla

I have few line segments as a graphic between points described by coordinates
(x,y) and I would like to align labels along each graphic segment with the
segment description. I was trying to use arctangent function but something is
Any suggestion?

30 cm

Bernard Liengme

Is the problem with ATAN or with aligning?
Please give us more info so we can help
best wishes

Dan Tabla

Sorry for the delayed answer..
I recorded a macro to see how it works and everthing is OK but:

Sub rotates()
With Selection
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlBottom
.WrapText = False
.Orientation = Worksheets("Sheet1").Cells(1, 1)
' cell (1,1) =DEGREES(ATAN(B1/B2))
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = True
End With
End Sub

when I changed .Orientation= Atn (1) didn't work and didn't even gave an
The script runs without an error or result.
I know that after I'll solve this problem I have to follow this algorithm...

Any suggestions? Seems too difficult for me for such a little job!!

Thank all of you and specialy to Bernard V Liengme!
PS. I have problem seeing OfficeLive page sorry for delayed answers!

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question