Thu, 04/27/2006 - 20:57
how can we use unit classes in our application ?
When we import some file(say STEP) we have way to know the units from
file, but how can it be linked to UnitsAPI ?
When I set UnitsAPI::SetLocalSystem, UnitsAPI::CurrentUnit("LENGTH") gives me an error. But, if I use UnitsAPI::SetCurrentUnit("LENGTH","mm"); before
UnitsAPI::CurrentUnit("LENGTH"), it works fine.
UnitsAPI::SetLocalSystem(UnitsAPI_MDTV );
UnitsAPI::SetCurrentUnit("LENGTH","mm");
Standard_CString temp = UnitsAPI::CurrentUnit("LENGTH"); >>>>>mm
Isn't there any connection between Local system and individual property unit ?
I mean given UnitsAPI::SetLocalSystem (UnitsAPI_MDTV) should have given me correct answer.
Also, if I again change localsystem, this happens
UnitsAPI::SetLocalSystem(UnitsAPI_SI);
Standard_CString temp = UnitsAPI::CurrentUnit("LENGTH"); >>>>> error>no resource "LENGTH"
Could any body tell me how it should be used ?
Thankyou
Ashish
Thu, 05/03/2012 - 20:28
hi , its old post maybe can help:
check your env variables : units api search for Lexi_Expr.dat