Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Im using VBA for AutoCAD and numbers in my drawing keep rounding.

3 REPLIES 3
Reply
Message 1 of 4
Anonymous
513 Views, 3 Replies

Im using VBA for AutoCAD and numbers in my drawing keep rounding.

hi there, im using VBA for AutoCAD and everything was fine but there's a major problem, everytime i ran my program all the lines showed up but the numbers keep rounding. For example when it's supposed to be 2,87 meters, it become 2 meters, or when it's supposed to be 3,1 meters, it become 3 meters.

 

I already change my units setting with decimals and 0.00000 precision but it doesnt change anything. Any help?

Tags (3)
3 REPLIES 3
Message 2 of 4
leeminardi
in reply to: Anonymous

Since 2,87 is displayed as 2 and not 3 I would guess the data type for the variable is Integer or Long and should be Double.  If 2,87 became 3 then it would indicate a rounding to zero decimal places.

lee.minardi
Message 3 of 4
Anonymous
in reply to: leeminardi

already changed it, result still the same. i tried to open the file in another laptop and it showed the correct number.

 

is the problem comes from my laptop?

Message 4 of 4
leeminardi
in reply to: Anonymous

This is very difficult to debug without the program and a sample file highlighting the problem.

lee.minardi

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

AutoCAD Inside the Factory


Autodesk Design & Make Report