Click here to Skip to main content
15,899,754 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: converting string to time Pin
David Crow12-Nov-09 2:39
David Crow12-Nov-09 2:39 
Questionre: sending a text message from main thread to a client thread Pin
Alan Kurlansky11-Nov-09 5:07
Alan Kurlansky11-Nov-09 5:07 
QuestionRe: re: sending a text message from main thread to a client thread Pin
David Crow11-Nov-09 5:12
David Crow11-Nov-09 5:12 
AnswerRe: re: sending a text message from main thread to a client thread Pin
Alan Kurlansky11-Nov-09 5:23
Alan Kurlansky11-Nov-09 5:23 
GeneralRe: re: sending a text message from main thread to a client thread Pin
David Crow11-Nov-09 5:27
David Crow11-Nov-09 5:27 
GeneralRe: re: sending a text message from main thread to a client thread Pin
Paulo Zemek11-Nov-09 5:29
Paulo Zemek11-Nov-09 5:29 
GeneralRe: re: sending a text message from main thread to a client thread Pin
Rajesh R Subramanian11-Nov-09 6:57
professionalRajesh R Subramanian11-Nov-09 6:57 
QuestionReading and writing files to the System Directory in Windows Vista using C++, MFC and fopen Pin
D_code_writer11-Nov-09 4:20
D_code_writer11-Nov-09 4:20 
Hey Guys,

I have an intresting problem for everyone to consider. One of my software projects reads and writes files to the system directory. It automatically detects the location of the Windows system directory, and then uses fopen to either read or write a file depending on what is required.

So here is the conundrum. These techniques work like a charm on my projects that I programmed using Visual C++ v6.0. No problem what so ever. I recently ported this project to Visual Studio 2008 using C++ and MFC, and for XP business as usual. However for Vista, disaster. The nature of the problem is that when I use fopen it can't open the file in the windows system directory. Basically I get (fp = fopen( m_keyPath, "w" or "r" )) == NULL. Here's the twist in the tale. Any where else it's fine. It's just the windows system directory.

Any ideas??

Best Regards

Danny
AnswerRe: Reading and writing files to the System Directory in Windows Vista using C++, MFC and fopen Pin
David Crow11-Nov-09 4:36
David Crow11-Nov-09 4:36 
AnswerRe: Reading and writing files to the System Directory in Windows Vista using C++, MFC and fopen Pin
Covean11-Nov-09 4:38
Covean11-Nov-09 4:38 
AnswerRe: Reading and writing files to the System Directory in Windows Vista using C++, MFC and fopen Pin
Rolf Kristensen11-Nov-09 9:19
Rolf Kristensen11-Nov-09 9:19 
GeneralRe: Reading and writing files to the System Directory in Windows Vista using C++, MFC and fopen Pin
D_code_writer11-Nov-09 22:56
D_code_writer11-Nov-09 22:56 
GeneralRe: Reading and writing files to the System Directory in Windows Vista using C++, MFC and fopen [modified] Pin
Rolf Kristensen11-Nov-09 23:10
Rolf Kristensen11-Nov-09 23:10 
QuestionCFileDialog creates problem under unicode standard Pin
m_mun11-Nov-09 4:20
m_mun11-Nov-09 4:20 
QuestionRe: CFileDialog creates problem under unicode standard Pin
David Crow11-Nov-09 4:28
David Crow11-Nov-09 4:28 
AnswerRe: CFileDialog creates problem under unicode standard Pin
m_mun11-Nov-09 4:30
m_mun11-Nov-09 4:30 
GeneralRe: CFileDialog creates problem under unicode standard Pin
David Crow11-Nov-09 4:32
David Crow11-Nov-09 4:32 
GeneralRe: CFileDialog creates problem under unicode standard [modified] Pin
m_mun11-Nov-09 4:34
m_mun11-Nov-09 4:34 
QuestionRe: CFileDialog creates problem under unicode standard Pin
David Crow11-Nov-09 4:42
David Crow11-Nov-09 4:42 
AnswerRe: CFileDialog creates problem under unicode standard Pin
m_mun11-Nov-09 4:46
m_mun11-Nov-09 4:46 
AnswerRe: CFileDialog creates problem under unicode standard Pin
m_mun11-Nov-09 4:55
m_mun11-Nov-09 4:55 
GeneralRe: CFileDialog creates problem under unicode standard Pin
David Crow11-Nov-09 5:14
David Crow11-Nov-09 5:14 
QuestionCreating a expert system and need some help please Pin
akshay174111-Nov-09 4:19
akshay174111-Nov-09 4:19 
AnswerRe: Creating a expert system and need some help please Pin
Richard MacCutchan11-Nov-09 7:48
mveRichard MacCutchan11-Nov-09 7:48 
AnswerRe: Creating a expert system and need some help please Pin
Maximilien11-Nov-09 9:44
Maximilien11-Nov-09 9: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.