This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes how do i get substring? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Beginning Java
Bookmark "how do i get substring?" Watch "how do i get substring?" New topic

how do i get substring?

Gemini Moses
Ranch Hand

Joined: Jan 04, 2001
Posts: 245
String S = filename.ext
I need the "ext" part of this string.
How can I get that?
Jessica Sant

Joined: Oct 17, 2001
Posts: 4313

Like this:

Check out the API for java.lang.String and java.lang.StringBuffer for more methods.

- Jess
Blog:KnitClimbJava | Twitter: jsant | Ravelry: wingedsheep
Gemini Moses
Ranch Hand

Joined: Jan 04, 2001
Posts: 245
Thanks Jessica for your quick help.
I am done with my code!!
Thanks a lot
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: how do i get substring?
It's not a secret anymore!