Click here to Skip to main content
14,450,486 members

C / C++ / MFC

 
AnswerRe: cout in color and perror - revisited Pin
leon de boer20-Dec-19 6:01
Memberleon de boer20-Dec-19 6:01 
GeneralRe: cout in color and perror - revisited Pin
Vaclav_20-Dec-19 6:48
MemberVaclav_20-Dec-19 6:48 
AnswerRe: cout in color and perror - revisited Pin
Richard MacCutchan20-Dec-19 7:07
communityengineerRichard MacCutchan20-Dec-19 7:07 
GeneralRe: cout in color and perror - revisited Pin
Vaclav_21-Dec-19 4:10
MemberVaclav_21-Dec-19 4:10 
GeneralRe: cout in color and perror - revisited Pin
Richard MacCutchan21-Dec-19 4:34
communityengineerRichard MacCutchan21-Dec-19 4:34 
GeneralRe: cout in color and perror - revisited Pin
Vaclav_21-Dec-19 10:05
MemberVaclav_21-Dec-19 10:05 
GeneralRe: cout in color and perror - revisited Pin
Richard MacCutchan21-Dec-19 22:25
communityengineerRichard MacCutchan21-Dec-19 22:25 
QuestionHow to close file in C++? Pin
Vaclav_19-Dec-19 18:13
MemberVaclav_19-Dec-19 18:13 
Yet another "problem" got me stumped.
To verify "networking" I use system call such as

system("vim /etc/hosts");


It does the job, however, I cannot figure out how to close the file.
The standard "vim" way is "Esc :q!" , and it is unclear which character should be "send" via standard console and which ones after responses from vim.
Either manually (cin) or as a string starting with "Esc".

Cheers
QuestionRe: How to close file in C++? Pin
CPallini19-Dec-19 22:35
mveCPallini19-Dec-19 22:35 
AnswerRe: How to close file in C++? Pin
Stefan_Lang19-Dec-19 22:59
mveStefan_Lang19-Dec-19 22:59 
AnswerRe: How to close file in C++? Pin
Vaclav_20-Dec-19 5:51
MemberVaclav_20-Dec-19 5:51 
AnswerRe: How to close file in C++? Pin
Richard MacCutchan19-Dec-19 22:56
communityengineerRichard MacCutchan19-Dec-19 22:56 
QuestionDo "setw(offset) " BEFORE cout ? Pin
Vaclav_18-Dec-19 5:22
MemberVaclav_18-Dec-19 5:22 
AnswerRe: Do "setw(offset) " BEFORE cout ? Pin
Richard MacCutchan18-Dec-19 5:56
communityengineerRichard MacCutchan18-Dec-19 5:56 
AnswerRe: Do "setw(offset) " BEFORE cout ? Pin
leon de boer18-Dec-19 6:19
Memberleon de boer18-Dec-19 6:19 
GeneralRe: Do "setw(offset) " BEFORE cout ? Pin
Vaclav_19-Dec-19 18:26
MemberVaclav_19-Dec-19 18:26 
GeneralRe: Do "setw(offset) " BEFORE cout ? Pin
Richard MacCutchan19-Dec-19 22:50
communityengineerRichard MacCutchan19-Dec-19 22:50 
AnswerRe: Do "setw(offset) " BEFORE cout ? Pin
CPallini18-Dec-19 11:43
mveCPallini18-Dec-19 11:43 
GeneralRe: Do "setw(offset) " BEFORE cout ? Pin
Vaclav_19-Dec-19 18:14
MemberVaclav_19-Dec-19 18:14 
QuestionLoadString Pin
Member 1450258317-Dec-19 0:36
MemberMember 1450258317-Dec-19 0:36 
AnswerRe: LoadString Pin
Daniel Pfeffer17-Dec-19 0:44
professionalDaniel Pfeffer17-Dec-19 0:44 
AnswerRe: LoadString Pin
Richard MacCutchan17-Dec-19 0:47
communityengineerRichard MacCutchan17-Dec-19 0:47 
QuestionLoadImage Failure Pin
ForNow15-Dec-19 15:17
MemberForNow15-Dec-19 15:17 
AnswerRe: LoadImage Failure Pin
leon de boer15-Dec-19 21:30
Memberleon de boer15-Dec-19 21:30 
GeneralRe: LoadImage Failure Pin
ForNow16-Dec-19 2:25
MemberForNow16-Dec-19 2:25 

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.