![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Mar 2005
Posts: 1
Rep Power: 0
![]() |
Can't open .REG files with fopen.
Hello, I'm currently attempting to create a program that can edit registry keys. I've managed to get C++ to export the registry to the file "registry.REG"
, but I can't get fopen to open the file. I'm new to C programming, so any thoughts would be appreciated. Thanks. |
|
|
|
|
|
#2 |
|
Expert Programmer
Join Date: Sep 2004
Location: Ontario, Canada
Posts: 550
Rep Power: 4
![]() |
What happens when you try to open them? Post your code
![]()
__________________
Johnny was a chemist's son but Johnny is no more, for what Johnny thought was H2O was H2SO4 |
|
|
|
|
|
#3 |
|
Newbie
Join Date: Mar 2005
Posts: 11
Rep Power: 0
![]() |
Make sure the name's right. Make sure the files' in the same directory as the executable OR that the filename is preceeded by the appropriate path. If fopen fails, check it's error status, maybe with perror() to see why it failed. In some cases you have to change a file's attributes to make sure it's readable. In some cases the file may be in use by another process. Checking error staus will point these things out.
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|