シェイプまたはチャートの ThreeDFormat の操作

考えられる使用シナリオ

Aspose.Cells はShape.ThreeDFormatプロパティと一緒に三次元フォーマット図形またはグラフの 3-D 形式を操作するためのクラス。の三次元フォーマットクラスには、アプリケーションの要件ごとに異なる結果を達成するために設定できるさまざまなプロパティが含まれています。

シェイプまたはチャートの ThreeDFormat の操作

次のサンプル コードは、ソースエクセルファイル最初のワークシートの最初の形状にアクセスし、サブプロパティを設定しますShape.ThreeDFormatプロパティに保存し、ワークブックを出力エクセルファイル.

// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-.NET
// The path to the documents directory.
string dataDir = RunExamples.GetDataDir(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
// Load excel file containing a shape
Workbook wb = new Workbook(dataDir + "sample.xlsx");
// Access first worksheet
Worksheet ws = wb.Worksheets[0];
// Access first shape
Shape sh = ws.Shapes[0];
// Apply different three dimensional settings
ThreeDFormat n3df = sh.ThreeDFormat;
n3df.ContourWidth = 17;
n3df.ExtrusionHeight = 32;
// Save the output excel file in xlsx format
wb.Save(dataDir + "output_out.xlsx");