Visit Jeremy's Blog.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 06-22-2006, 05:59 AM   #1
LQ Newbie
Registered: May 2006
Posts: 28

Rep: Reputation: 15
to get a substring

I use QT Designer
I have a string

QString filename="/data/home/dimah/summer.txt

I need to get only "summer"
So i used


and got "/data/home/dimah/summer"
How to get "summer" only.
Old 06-22-2006, 06:31 AM   #2
Registered: Aug 2005
Location: Germany
Distribution: Ubuntu, Debian
Posts: 189

Rep: Reputation: 31
Have a look here:

I think you are able to find a proper solution using that method.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
extract substring from string in C baddah Programming 6 02-02-2010 04:22 AM
replace a substring with another string in C zeppelin Programming 21 11-09-2009 09:59 PM
how many occurances of a substring are they n a string linuxmandrake Programming 1 04-11-2006 02:02 AM
Replace substring with SED marri Programming 2 07-09-2005 05:18 PM
how to find an exact substring match? ldp Programming 7 02-22-2005 06:28 AM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 10:03 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration