Managing Currency Symbols
Managing Currency Symbols
The CurrencySymbol property exposed by the Project class is used to set or get the currency symbol. This property supports the string data type.
To see a project’s currency symbol in Microsoft Project:
- From the Tools menu, select Options.
- Select the View tab.
Viewing the currency symbol in Microsoft Project
Setting Currency Symbol using Aspose.Tasks
The following example shows how to set a currency symbol for a project.
1// For complete examples and data files, please go to https://github.com/aspose-tasks/Aspose.Tasks-for-Java
2// The path to the documents directory.
3String dataDir = Utils.getDataDir(CurrencySymbols.class);
4
5Project project = new Project();
6project.set(Prj.CURRENCY_SYMBOL, "$$");
Getting Currency Symbol using Aspose.Tasks
Access the currency symbol using a project’s CurrencySymbol:
1// For complete examples and data files, please go to https://github.com/aspose-tasks/Aspose.Tasks-for-Java
2// The path to the documents directory.
3String dataDir = Utils.getDataDir(CurrencySymbols.class);
4
5Project project = new Project(dataDir + "project5.mpp");
6System.out.println(project.get(Prj.CURRENCY_SYMBOL));