Skip to main content
Solved

float to integer

  • September 23, 2024
  • 2 replies
  • 61 views

Forum|alt.badge.img

Hi,

 

Is there a way to change variable from float to integer?

I want to use it to write list of polygons in loop:

for i:n:

polygon_name 1.pob

polygon_name 2.pob

polygon_name 3.pob

….

In other words, i dont want something like that:

 

Thanks,

Nadav

…..

 

Best answer by Sean Turner

Use the FORMAT keyword to change to an integer. 

FORMAT m INT 
The optional keyword INT indicates the value should be first converted to an integer and printed in integer format using the number of places specified by m.

View original
Did this topic help you find an answer to your question?

2 replies

Sean Turner
Ultraviolet
Forum|alt.badge.img+1
  • Ultraviolet
  • 88 replies
  • Answer
  • September 23, 2024

Use the FORMAT keyword to change to an integer. 

FORMAT m INT 
The optional keyword INT indicates the value should be first converted to an integer and printed in integer format using the number of places specified by m.


Forum|alt.badge.img
  • Author
  • Fully Spectral
  • 89 replies
  • September 23, 2024

Hi Sean,

It works,

Thank you very much,

Nadav


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings