Ausblenden der Anzeige von Nullwerten im Arbeitsblatt
Contents
[
Hide
]
Manchmal müssen Sie Nullwerte in einer Tabelle ausblenden. Dies kann eine persönliche Vorliebe oder ein Formatierungsstandard sein.
So blenden Sie Nullwerte in einem Arbeitsblatt in Microsoft Excel aus (z. B. Microsoft Excel 2003):
- Von demWerkzeug Menü, auswählenOptionen , und wählen Sie dann die ausSicht Tab.
- Deaktivieren Sie dieNullwerte Möglichkeit.
- KlickenOK.
Ausblenden von Nullwerten in Microsoft Excel
Bitte sehen Sie sich den folgenden Beispielcode an, der zeigt, wie Nullen mit Aspose.Cells ausgeblendet werden.
This file contains hidden or 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-Java | |
// The path to the documents directory. | |
String dataDir = Utils.getDataDir(HidingDisplayOfZeroValues.class); | |
// Create a new Workbook object | |
Workbook workbook = new Workbook(dataDir + "book1.xlsx"); | |
// Get First worksheet of the workbook | |
Worksheet sheet = workbook.getWorksheets().get(0); | |
// Hide the zero values in the sheet | |
sheet.setDisplayZeros(false); | |
// Save the workbook | |
workbook.save(dataDir + "output.xls"); |