我正在excel中画一个圆圈,里面有一个数字,但是一旦这个数字达到两位数,第二个数字就不可见了。
我希望textsize适合形状。
我不能更改圆的大小,因为这是基于机会值的。
我正在处理业务漏斗,该漏斗的相关输入为: - 票号 -机会价值(潜在收入):用于确定圈子的大小
圆圈在漏斗中绘制,漏斗分为四个阶段,分别表示为四个形状。
我尝试过:
Public Function DrawCircle(x As Integer, y As Integer, tickets As Collection, ticketIndex As Integer)
Dim myCircle As Shape
Dim circleSize As Integer
circleSize = GetTicketSize(tickets, ticketIndex)
Dim name As String
name = "" & tickets.Item(ticketIndex).id
Set myCircle = ThisWorkbook.Sheets("Graphic funnel").Shapes.AddShape(msoShapeOval, x, y, circleSize, circleSize)
myCircle.Select
Selection.ShapeRange.Fill.Visible = msoTrue
Selection.ShapeRange.TextFrame.Characters.Text = name
Selection.ShapeRange.Left = Selection.ShapeRange.Left
Selection.ShapeRange.Top = Selection.ShapeRange.Top - circleSize / 2
With myCircle
.DeleteText
.wrapformat = msoWrapFormat
.WordWrap = True
.AutoSize = msoAutoSizeTextToFitShape
End With
但是它返回:“对象不支持此属性或方法”