Converti le date in date giapponesi
Contents
[
Hide
]
Nel calendario giapponese ** **, una nuova era inizia con il regno di un nuovo imperatore. Il 1° maggio 2019 è salito al potere un nuovo imperatore con il quale è finita l’era Heisei ed è iniziata l’era Reiwa.
Aspose.Cells fornisce un modo per convertire le date gregoriane in date giapponesi. Durante questa conversione, vengono considerati anche i cambiamenti dell’epoca. Il seguente frammento di codice converte il filefonte Excel file contenente date gregoriane aluscita PDF con date giapponesi come mostrato nell’immagine qui sotto.
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-.NET | |
//Source directory | |
string sourceDir = RunExamples.Get_SourceDirectory(); | |
//Output directory | |
string outputDir = RunExamples.Get_OutputDirectory(); | |
LoadOptions options = new LoadOptions(LoadFormat.Xlsx); | |
options.CultureInfo = new CultureInfo("ja-JP"); | |
Workbook workbook = new Workbook(sourceDir + "JapaneseDates.xlsx", options); | |
workbook.Save(outputDir + "JapaneseDates.pdf", SaveFormat.Pdf); |