Click here to Skip to main content
15,905,683 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionSpeech-to-Text Programme compilation error ...... Pin
CoolDude287817-Sep-08 2:56
CoolDude287817-Sep-08 2:56 
AnswerRe: Speech-to-Text Programme compilation error ...... Pin
enhzflep17-Sep-08 3:19
enhzflep17-Sep-08 3:19 
GeneralRe: Speech-to-Text Programme compilation error ...... Pin
CoolDude287817-Sep-08 4:48
CoolDude287817-Sep-08 4:48 
GeneralRe: Speech-to-Text Programme compilation error ...... Pin
enhzflep17-Sep-08 6:49
enhzflep17-Sep-08 6:49 
QuestionHow can I get the pressure of the use of the touchpad notebook Pin
armctec17-Sep-08 2:49
armctec17-Sep-08 2:49 
QuestionProcess Handle Pin
Ali Tavakol17-Sep-08 2:40
Ali Tavakol17-Sep-08 2:40 
AnswerRe: Process Handle [modified] Pin
Roger Stoltz17-Sep-08 2:55
Roger Stoltz17-Sep-08 2:55 
QuestionIs Cdrtools(CD/DVD authoring tools) source code available in VC++ or .Net? Pin
Karthik.M17-Sep-08 2:32
Karthik.M17-Sep-08 2:32 
QuestionPlease Help me any body......... Pin
m_mun17-Sep-08 2:22
m_mun17-Sep-08 2:22 
QuestionRe: Please Help me any body......... Pin
CPallini17-Sep-08 5:42
mveCPallini17-Sep-08 5:42 
AnswerRe: Please Help me any body......... Pin
Hamid_RT17-Sep-08 8:26
Hamid_RT17-Sep-08 8:26 
JokeRe: Please Help me any body......... Pin
CPallini17-Sep-08 10:14
mveCPallini17-Sep-08 10:14 
AnswerRe: Please Help me any body......... Pin
Mark Salsbery17-Sep-08 6:19
Mark Salsbery17-Sep-08 6:19 
GeneralRe: Please Help me any body......... Pin
CPallini17-Sep-08 10:17
mveCPallini17-Sep-08 10:17 
GeneralRe: Please Help me any body......... Pin
Mark Salsbery17-Sep-08 10:25
Mark Salsbery17-Sep-08 10:25 
AnswerRe: Please Help me any body......... Pin
Hamid_RT17-Sep-08 8:30
Hamid_RT17-Sep-08 8:30 
QuestionNotifying Parent Dialog about the child control changes Pin
Vikas_12317-Sep-08 1:46
Vikas_12317-Sep-08 1:46 
Questioncopy content 2 file.txt ==> output.txt Pin
aa_zz17-Sep-08 1:12
aa_zz17-Sep-08 1:12 
char* t1 = "C:\\a.txt";
char* t2 = "C:\\b.txt";
char* t3 = "c:\\c.txt";

(VC++6.0)please guide I copy content of 2 a and b to c ???. thanks very much

I coded ERROR. open binary ==> it will read \r\n ==>error

e.g:
file a.txt
ABCDED
file b.txt
DDDDDDDDD
file c.txt. ==>>
ABCDED
DDDDDDDDD



content coded

bool copyFile (const char SRC[], const char INPUT2[], const char DEST[])
{
std::ifstream src; // the source file
std::ifstream input2;
std::ofstream dest; // the destination file
src.open (SRC, std::ios::binary); // open in binary to prevent jargon at the end of the buffer
input2.open(INPUT2, std::ios::binary);
dest.open (DEST);//, std::ios::binary); // same again, binary

if (!src.is_open() || !dest.is_open())
return false; // could not be copied
dest << src.rdbuf (); // copy the content
dest << input2.rdbuf();

dest.close (); // close destination file
src.close (); // close source file

return true; // file copied successfully
}

int main(int argc, char* argv[])
{

if (!copyFile ("C:\\n\\po7.txt", "C:\\n\\po8.txt", "C:\\npo8888.txt"))
std::cout << "File could not be copied successfully";
else
std::cout << "File copied successfully!";

std::cin.get (); // pause for input

return 0;
}
AnswerRe: copy content 2 file.txt ==&gt; output.txt Pin
enhzflep17-Sep-08 2:45
enhzflep17-Sep-08 2:45 
QuestionString Convert Pin
si_6917-Sep-08 0:53
si_6917-Sep-08 0:53 
AnswerRe: String Convert Pin
toxcct17-Sep-08 0:59
toxcct17-Sep-08 0:59 
GeneralRe: String Convert Pin
CPallini17-Sep-08 2:58
mveCPallini17-Sep-08 2:58 
GeneralRe: String Convert Pin
toxcct17-Sep-08 3:05
toxcct17-Sep-08 3:05 
GeneralRe: String Convert Pin
PJ Arends17-Sep-08 9:53
professionalPJ Arends17-Sep-08 9:53 
GeneralRe: String Convert Pin
toxcct17-Sep-08 9:59
toxcct17-Sep-08 9:59 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.