Welcome to WEAP's Website WEAP
WEAP is an initiative of the Stockholm Environment Institute.


About WEAP

Home
Why WEAP?
Features
What's New?
Sample Screens
Demonstration
Publications
History and Credits

Using WEAP
Download
Licensing
User Guide
Tutorial
Videos (YouTube)

User Forum
Discussions
Members List
Edit Profile

Additional Support
Training
University Courses
Collaboration

About Us
SEI-US Water Resources Program
Please Contact Us

LEAP
Interested in Energy?
Read about LEAP: SEI's software for energy planning.

Link WEAP and LEAP for combined Water-Energy planning.
Watch a video demo!
   

User Forum

All Topics | Topic "Unit of the area on Cachment with API"
Log in to post new messages or reply to existing messages.
 
Author Message
Mr. Ignacio Aguirre

Subject: Unit of the area on Cachment with API   
Posted: 8/27/2020 Viewed: 6432 times
Hello

I have been using the API to create catchment-type nodes, however, I have not been able to insert the unit of the area [km2] through it, but I had to do it manually one by one, how can you insert the unit of the area in the catchments through the API?
Currently, I use it through Python and VB.

Regards
Mr. Jack Sieber

Subject: Re: Unit of the area on Cachment with API   
Posted: 8/29/2020 Viewed: 6428 times
Yes, you can change the unit via the API, using the ScaleUnit property of the WEAPVariable class. Here's an example:

WEAP.Branch("\Demand Sites and Catchments\Big Farm").Variables("Area").ScaleUnit = "km^2"

Jack

Topic "Unit of the area on Cachment with API"