Click here to Skip to main content
15,885,546 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: int value through string Pin
CodingLover4-Dec-07 19:37
CodingLover4-Dec-07 19:37 
GeneralRe: int value through string Pin
Hamid_RT4-Dec-07 19:38
Hamid_RT4-Dec-07 19:38 
GeneralRe: int value through string Pin
CodingLover4-Dec-07 20:19
CodingLover4-Dec-07 20:19 
QuestionRe: int value through string Pin
David Crow5-Dec-07 2:49
David Crow5-Dec-07 2:49 
GeneralRe: int value through string Pin
Nelek5-Dec-07 3:43
protectorNelek5-Dec-07 3:43 
GeneralUse of SetWindowsHookEx detectd as spyware Pin
Sudhir Mangla4-Dec-07 18:16
professionalSudhir Mangla4-Dec-07 18:16 
GeneralRe: Use of SetWindowsHookEx detectd as spyware Pin
Naveen4-Dec-07 20:42
Naveen4-Dec-07 20:42 
Questionwhy rename would fail sometimes? Pin
kcynic4-Dec-07 15:01
kcynic4-Dec-07 15:01 
Hello everyone.In my program,I want to change a file's content,so I create a create file to copy data from source file and write new data,too.
When all file reading and writing completed,I want to delete the source file and rename the temp file to the source file name.If the source file path is sourcePath,and the temp file path is tempPath,my codes look like following:
if(remove(sourcePath)==0)//sourcePath is the full path of the source file
rename(tempPath,sourcePath);
Of course,the source and temp file are in the same directory.

But it is strange that,if i separate the codes as a short test console project,it works well!
Someones would like to tell me why?
Thanks.

GOOD LUCK
AnswerRe: why rename would fail sometimes? Pin
David Crow4-Dec-07 16:51
David Crow4-Dec-07 16:51 
AnswerRe: why rename would fail sometimes? Pin
Hamid_RT4-Dec-07 18:16
Hamid_RT4-Dec-07 18:16 
GeneralUnwanted control characters in a CString Pin
Tom Paronis4-Dec-07 13:36
Tom Paronis4-Dec-07 13:36 
QuestionRe: Unwanted control characters in a CString Pin
David Crow4-Dec-07 16:43
David Crow4-Dec-07 16:43 
GeneralCalling CreateProcessAsUser from service on to Winsta0//winlogon desktop in Vista. Pin
Ronakkumar Patel4-Dec-07 9:18
Ronakkumar Patel4-Dec-07 9:18 
GeneralCImage and VC++ 6 Pin
RomTibi4-Dec-07 9:11
RomTibi4-Dec-07 9:11 
GeneralRe: CImage and VC++ 6 Pin
David Crow4-Dec-07 10:34
David Crow4-Dec-07 10:34 
GeneralRe: CImage and VC++ 6 Pin
Hamid_RT4-Dec-07 18:20
Hamid_RT4-Dec-07 18:20 
GeneralAdding WM_VSCROLL to message handler for slider control in VS 2005 with C++ and MFC Pin
GrizzlyDoug4-Dec-07 8:04
GrizzlyDoug4-Dec-07 8:04 
GeneralRe: Adding WM_VSCROLL to message handler for slider control in VS 2005 with C++ and MFC Pin
Mark Salsbery4-Dec-07 8:31
Mark Salsbery4-Dec-07 8:31 
GeneralGDI+ samples and malloc/free [modified] Pin
bob169724-Dec-07 7:16
bob169724-Dec-07 7:16 
GeneralRe: GDI+ samples and malloc/free Pin
David Crow4-Dec-07 7:22
David Crow4-Dec-07 7:22 
GeneralRe: GDI+ samples and malloc/free Pin
bob169724-Dec-07 7:41
bob169724-Dec-07 7:41 
GeneralRe: GDI+ samples and malloc/free Pin
DoomedOne4-Dec-07 9:20
DoomedOne4-Dec-07 9:20 
Questiondll using in VB or VC# Pin
kingday4-Dec-07 7:09
kingday4-Dec-07 7:09 
GeneralRe: dll using in VB or VC# Pin
CPallini4-Dec-07 9:22
mveCPallini4-Dec-07 9:22 
QuestionAlternatives to IExpress? Pin
chaiguy13374-Dec-07 5:44
chaiguy13374-Dec-07 5:44 

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.