ThreeDFormat.IncrementRotationX 方法 (Excel)ThreeDFormat.IncrementRotationX method (Excel)

按照指定的度數,變更指定圖案繞 X 軸旋轉的角度。Changes the rotation of the specified shape around the x-axis by the specified number of degrees. 您可以使用 RotationX 屬性來設定圖案繞 X 軸旋轉的絕對角度。Use the RotationX property to set the absolute rotation of the shape around the x-axis.


運算式IncrementRotationX遞增值expression.IncrementRotationX (Increment)

_運算式_代表**ThreeDFormat** 物件的變數。expression A variable that represents a ThreeDFormat object.


名稱Name 必要/選用Required/Optional 資料類型Data type 描述Description
IncrementIncrement 必要Required SingleSingle 指定圖案繞 X 軸旋轉的變更量 (以度為單位)。Specifies how much (in degrees) the rotation of the shape around the x-axis is to be changed. 可以是介於-90 到 90 值。Can be a value from -90 through 90. 正值會使圖案向上傾斜,負值會使圖案向下傾斜。A positive value tilts the shape up; a negative value tilts it down.


您不能調整指定的圖案繞 x 軸過去的RotationX屬性 (向-90 度旋轉 90 度) 的上方或下方限制。You cannot adjust the specified shape's rotation around the x-axis past the upper or lower limit for the RotationX property (90 degrees to -90 degrees). 例如,如果RotationX屬性最初設為 80,且您指定的_遞增值_引數的 40、 所產生的旋轉角度會是 90 (上限的RotationX屬性),而不是 120。For example, if the RotationX property is initially set to 80 and you specify 40 for the Increment argument, the resulting rotation will be 90 (the upper limit for the RotationX property) instead of 120.

若要變更的圖案繞 y 軸的旋轉角度,請使用 IncrementRotationY 方法。To change the rotation of a shape around the y-axis, use the IncrementRotationY method. 若要變更繞 z 軸的旋轉角度,請使用**IncrementRotationZ** 方法。To change the rotation around the z-axis, use the IncrementRotationZ method.


本範例使 myDocument 中的第一個圖案向上旋轉 10 度。This example tilts shape one on myDocument up 10 degrees. 只有當第一個圖案是有深度的圖案時,才能看到本範例的效果。Shape one must be an extruded shape for you to see the effect of this code.

Set myDocument = Worksheets(1) 
myDocument.Shapes(1).ThreeD.IncrementRotationX 10

支援和意見反應Support and feedback

有關於 Office VBA 或這份文件的問題或意見反應嗎?Have questions or feedback about Office VBA or this documentation? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.