As default, the API does not include a Heureka price list which means that for example timber and pulwood volumes obtained when harvesting is not accessible. However, if you provide a pricelist, these can be obtained. You can either activate a default price list, or provide a path to a price list file, by adding it to a GrowthCalculator, see code examples below.
A Heureka price list is stored as a file and can be created in StandWise, PlanWise or RegWise. Price lists are by default placed in My Documents \ Heureka \ Common \ Pricelists, or in a Heureka project folder, for example in My Documents \ Heureka \ Projects \ PlanWise \ ProjectName \ Pricelists.
| Active default price list |
Copy Code |
|---|---|
// Requires that file "pricelist.default.gzip" in subfolder EmbeddedData is included in the projet. GrowthCalculator gc = new GrowthCalculator(); gc.AddDefaultPriceList(); // In this case, you must ensure that the growth calculator is used, by passing it as argument in calls to the ApiCompartment's growth methods, or assign it explitly to the ApiCompartment when it has first been created: compartment.GrowthCalculator = gc; | |
| Add price list from file |
Copy Code |
|---|---|
GrowthCalculator gc = new GrowthCalculator(); string path = "C:\\temp\\myHeurekaPriceList.pricelist"; gc.AddPriceListFromFile(path); | |