# Converting a string to an integer

**URL:** <https://forum.kirupa.com/t/converting-a-string-to-an-integer/87509>\
**Category:** flash\
**Created:** [April 21, 2005, 4:00pm UTC](https://forum.kirupa.com/t/converting-a-string-to-an-integer/87509 "2005-04-21T16:00:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hommer](https://avatars.discourse-cdn.com/v4/letter/h/a3d4f5/32.png) [@Hommer](https://forum.kirupa.com/u/Hommer)\
**Post date:** [April 21, 2005, 4:00pm UTC](https://forum.kirupa.com/t/converting-a-string-to-an-integer/87509/1 "2005-04-21T16:00:45Z")

</div>

I’m loading some data from an external .txt-file.  
In the .txt-file i have this:  
number=40  
I want to manipulate the number like this:  
newNumber = this.number+1;  
…in order to get the new number to be 41, but when I load the number from the .txt-file it is loaded as a string (am I not right?).  
How do I convert the number to be an integer instead of a string, so I can manipulate it?
