Click here to Skip to main content
15,909,199 members
Home / Discussions / Managed C++/CLI
   

Managed C++/CLI

 
GeneralC# and Custom C++ interfaces Pin
vad_kr27-Feb-05 21:06
vad_kr27-Feb-05 21:06 
GeneralRe: C# and Custom C++ interfaces Pin
ursus zeta28-Feb-05 14:20
ursus zeta28-Feb-05 14:20 
GeneralSyntax for storing an adress to a function pointer from outside a class in GNU g++ Pin
Armini25-Feb-05 7:29
Armini25-Feb-05 7:29 
GeneralSimple 'DateTimePicker' Question Pin
lior654#hotmail.com24-Feb-05 21:07
lior654#hotmail.com24-Feb-05 21:07 
GeneralRe: Simple 'DateTimePicker' Question Pin
lms0073-Mar-05 22:02
lms0073-Mar-05 22:02 
GeneralC++ Functions Pin
opan24-Feb-05 19:49
opan24-Feb-05 19:49 
GeneralRe: C++ Functions Pin
Christian Graus28-Feb-05 10:04
protectorChristian Graus28-Feb-05 10:04 
GeneralFile I/O problem Pin
Anonymous22-Feb-05 13:27
Anonymous22-Feb-05 13:27 
Hi,
I am new to C++ programming. I am using the following code to check if a file exists, if not then create a new file and input something into the file.
the code runs well for the first time and creates the file as desired, however if the file created is manually deleted from the specified directory then the file is no longer created. I don't why ????????
Appreciate any help in this regard

ifstream dbfile("/var/puremail/tmp/pm_db_down.txt");

if (!dbfile.is_open()) {

cout << "The file does not exist. Creating a new file" << endl;
ofstream dbfile ("/var/puremail/tmp/pm_db_down.txt");
dbfile << puremail.m_getTime << endl;
dbfile.close();
exit(2);
}
else {
// read the file and calculate the time for which the db is down
}

when this code is run for the first time the file was created and also the time was written into the file, however after deleting the dbfile if I again run the code, the file is no more created.
Appreciate any help in this regard.
Thanks,
Mohit.Sigh | :sigh:
GeneralThis is the managed C++ Forum (.NET) Pin
ursus zeta24-Feb-05 10:24
ursus zeta24-Feb-05 10:24 
Generalgraphics Pin
gyanendra suwal18-Feb-05 6:37
gyanendra suwal18-Feb-05 6:37 
Generalimport .jpg file Pin
ursus zeta19-Feb-05 11:05
ursus zeta19-Feb-05 11:05 
Generalproblem in graphics Pin
18-Feb-05 6:13
suss18-Feb-05 6:13 
GeneralRe: problem in graphics Pin
ursus zeta19-Feb-05 11:17
ursus zeta19-Feb-05 11:17 
GeneralRe: problem in graphics Pin
sunibigyana20-Feb-05 6:44
susssunibigyana20-Feb-05 6:44 
GeneralRe: problem in graphics Pin
ursus zeta24-Feb-05 10:58
ursus zeta24-Feb-05 10:58 
Generalkindly help me with this errors: Pin
jedskie_a17-Feb-05 6:19
jedskie_a17-Feb-05 6:19 
GeneralRe: kindly help me with this errors: Pin
ursus zeta19-Feb-05 11:11
ursus zeta19-Feb-05 11:11 
GeneralApplication quits prematurely Pin
SACHITHA16-Feb-05 22:59
SACHITHA16-Feb-05 22:59 
GeneralExpose COM interface from managed C++ Pin
e1e0n16-Feb-05 9:08
e1e0n16-Feb-05 9:08 
GeneralClient/Server Pin
densitet16-Feb-05 6:18
densitet16-Feb-05 6:18 
GeneralPrinter - Escape Sequence Pin
tjuentgen16-Feb-05 1:59
tjuentgen16-Feb-05 1:59 
GeneralRe: Printer - Escape Sequence Pin
Christian Graus16-Feb-05 9:56
protectorChristian Graus16-Feb-05 9:56 
Questionparser? Pin
jedskie_a14-Feb-05 13:26
jedskie_a14-Feb-05 13:26 
AnswerRe: parser? Pin
RNEELY18-Feb-05 8:59
RNEELY18-Feb-05 8:59 
GeneralRe: parser? Pin
jedskie_a18-Feb-05 12:41
jedskie_a18-Feb-05 12:41 

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.