stass3d Posted November 25, 2008 Share Posted November 25, 2008 (edited) Hi All! I`ve a small question. Is there the way to convert primitive string attribute to primitive int attribute? Attribute contain the string like "7". Thank you in advance! Edited November 25, 2008 by stass3d Quote Link to comment Share on other sites More sharing options...
stass3d Posted November 25, 2008 Author Share Posted November 25, 2008 I cleared the question by myself! It is possible by using of atof() expression function Quote Link to comment Share on other sites More sharing options...
stevenong Posted November 25, 2008 Share Posted November 25, 2008 Hi, If the string attribute contains just numbers, you can use prims() with atof(). To convert to integer, use the int() function. int(atof(prims("/obj/geo1/sop",0,foo))) Cheers! steven Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.