Hello LEAP team!
I am trying to output my Energy Balance to Excel and it seems to be going well. I have a few problems though, that I hope You can help with:
- When I specify my unit [LEAP.ActiveUnit = "Terawatt-hour"], I get my results in Thousand Terawatt-hours. This is an issue if I am using "CopyEnergyBalanceTable" method, as the data cots at 2 decimals. Is there something I can do to either remove the annoying scaling or get more decimals through code?
- It seems like I cannot get the same detail level in API as I can manually. Using [LEAP.EnergyBalanceColumns], I cannot seems to get the Demand Detail of Fuels, Sectors and Subsectors, which I really would like. Am I wrong?
Edit: I tried changing the unit to Megawatt-hours, but then the model changed it to "Billion Megawatt-hours", so no improvement in doing that.
Edit2: I tried setting my scenario, region, unit and Demand detail manually in the Energy Balance view and then running my code from VBA:
- Using "CopyEnergyBalanceTable", everything but the unit scale was fixed. LEAP decides itself which unit I should have, not great
- Using "ExportEnergyBalanceXLS", everything stayed fixed, even the unit scale (Yay!).... the first time. The second time I ran my code, it reverted to its favorite scale again. Not super practical.