Topic profile page for Std string.
This page has aggregated data from forum posts, threads, listings, online discussions, newsgroups, messageboards, and other online sources which contain user generated content for the term: Std string.
Topic "Std string" was discussed 1,792 times on 116 sites in last 3 months
Started 2 days, 6 hours ago (2009-11-09 13:55:00)
by bajajv Member
Hello, I am trying to implement the CString class. I can implement the functions using the standard namespace string class, but not sure whether it will support the wide characters or not. Also, please suggest that how can I check for characters of other languages? Can I get characters of other languages by changing the language settings of my machine?
Started 6 days ago (2009-11-05 19:24:00)
by Swerve
I have a task to do about the std::string datatype. To do the task I need to use the KDevelop IDE and be able to find the size of the buffer being used when performing operations upon strings, but never having used KDevelop before, I'm at a complete loss. Could anyone be so kind as to give me some direction as how to go about viewing a buffer which is in use? Can it's contents be ...
Started 2 weeks ago (2009-10-28 09:52:00)
by StasV
Hello! I have such a function. Code: TBuf Utils::LoadMessageL(int mesageId) { TBuf text; text.Copy(_L("Some text")); return text; } Everything works just fine. But code scanner in carbide IDE tells me, that I am returning-descriptor-out-of-scope. Am I? Please, note, that Code: iUserManager->iUserLogin= iUserLogin; also works fine for me. ...
Started 2 weeks, 4 days ago (2009-10-24 16:03:00)
by bengreenwood
Hi, I have a function in a program that's something like the following. When I try to output what it returns, however, it doesn't print anything on the screen. The following isn't exactly what I'm using, but it gets the point across. Code: const char* getcolor(bool top) { stringstream color_convert; string string1; if (top == 1) color_convert
Started 1 month ago (2009-10-12 01:00:00)
by jh7777
Hi there I wonder if anyone could help me with the following C++ question: I've been given a custom-made string class which handles string, wstring and bstr. It has a number of methods and assignment operators to convert to and from different types. The app I work on compiles happily in VS6 and VS2008, but when trying to compile in Redhat (version 4.1.1 in Redhat 5.0), for example for ...
Started 1 month ago (2009-10-05 22:41:00)
by kenrus
What are some ways to determine if a std::string contains all numeric data? (Alpha representations of numeric data) Code: std::string sPrimaryNumber = "98"; sPrimaryNumber.find_first_not_of("0123456789");
Started 1 month, 1 week ago (2009-10-03 05:43:00)
by jasperleeabc
Hi, I am having a very strange problem with std::string. Here's the code: Code: char temp[100]; gets(temp); printf("%s", temp); string t(temp); I did "using namespace std;", and now Code: string t(temp) is not working. Any ideas? My input was "lee". Thanks.
Started 1 month, 2 weeks ago (2009-09-22 14:50:54)
by Darth Vader
I have a native code snippet that I am going to write in managed code instead. The native snippet code look like this: Help with Code Tags C++ Syntax ( Toggle Plain Text ) std:: string RClammer = "]" ; std:: string BigLine = "aaaaaaaa]aaaa" ; int pos = 0 ; while ( std:: string :: npos != ( pos = BigLine. find ( RClammer, pos ) ) )...
Started 1 day, 10 hours ago (2009-11-10 09:16:00)
by Yarin
You mentioned manipulating the string. STL string manipulation isn't done as it is in C, you can read about it here: C++ Reference You can use the c_str() member to get a C style string if you need to (non-manipulative, though).
Started 2 days, 3 hours ago (2009-11-09 16:16:00)
by Banfa
std:string is based on char and therefore does not support wide characters, but can support multi-byte characters. std::wstring is based on wchar_t and supports wide characters.
Started 4 days, 20 hours ago (2009-11-07 00:00:00)
by Clinton Portis
The string member capacity() is defined as: • • • • Return size of allocated storage Returns the size of the allocated storage space in the string object. Notice that the capacity is not necessarily equal to the number of characters that conform the content of the string (this can be obtained with members size or length), but the capacity of the allocated space,...
Started 5 days, 18 hours ago (2009-11-06 01:13:42)
by dkalita
may be u can display using cout as Help with Code Tags C++ Syntax ( Toggle Plain Text ) string str; char *buf = ( char * ) &str; /*u need to know the size of 'str'*/ /*sizeof(str) might work but m not sure about it*/ int i; for ( i= 0 ;i