تعيين لون علامة التبويب للورقة العمل
Contents
[
Hide
]
تسمح Aspose.Cells لك بتغيير لون علامات تبويب ورق العمل الفردية لتمييزها عن البقية. على سبيل المثال، يمكنك جعل تكاليف بلون أحمر، ومبيعات بلون أخضر، وأصول بلون أزرق، وما إلى ذلك.
ضبط لون علامة تبويب ورق العمل باستخدام Microsoft Excel
- انقر بزر الماوس الأيمن فوق علامة تبويب في ورقة العلامات في أسفل ورقة العمل الحالية.
- حدد لون العلامة التبويب.
- حدد لونًا من اللوحة.
- انقر على موافق.
تعيين لون علامة تبويب الورقة العمل باستخدام Aspose.Cells
الشيفرة المثالية أدناه تظهر كيفية تعيين لون علامة تبويب باستخدام Aspose.Cells.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 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); | |
// Instantiate a new Workbook | |
// Open an Excel file | |
Workbook workbook = new Workbook(dataDir+ "Book1.xlsx"); | |
// Get the first worksheet in the book | |
Worksheet worksheet = workbook.Worksheets[0]; | |
// Set the tab color | |
worksheet.TabColor = Color.Red; | |
// Save the Excel file | |
workbook.Save(dataDir+ "worksheettabcolor.out.xls"); |