
Anonymous
Not applicable
2011-03-21
10:22 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How to convert Long to String and String to Long
HI,
Could any one post the solution for converting Long to String and String to Long.
Thanks,
-Teja
Could any one post the solution for converting Long to String and String to Long.
Thanks,
-Teja
797 Views
2 Replies

Anonymous
Not applicable
2011-03-21
10:38 AM
Author
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Long to String:
String to Long:
<var>.toString()
//to protect agianst null pointers:
<var> == null ? null : var.toString()
String to Long:
Long.parseLong(<var>)
797 Views

Anonymous
Not applicable
2011-03-21
11:10 AM
Author
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you have to do a lot of this type of conversion, you may want to consider tConvertType.
This is a link to a video that converts Strings to Longs w/o having to add Java in expressions.
http://bekwam.blogspot.com/2011/02/tutorial-converting-data-types-with.html
-Carl
This is a link to a video that converts Strings to Longs w/o having to add Java in expressions.
http://bekwam.blogspot.com/2011/02/tutorial-converting-data-types-with.html
-Carl
797 Views
