Posted on 1999-01-16
I know this is the Delphi topic area...but I'm hoping some of you Delphi gurus may know how to solve this:
I am writing a program in C++ Builder. I'm using the string ADT and a Memo component. I'm trying to do the following:
TempPalindrome = MemoPalindromeCandidates->Lines;
This is not working because Lines is of type TStrings. I need something that is compatible with the string ADT. For example an AnsiString would be compatible:
//This works okay.
TempPalindromeFile = openDlg->FileName.c_str();
Because FileName is an AnsiString, you can add c_str() on the end and assign the whole thing to TempPalindromeFile.