Click here to Skip to main content
15,900,457 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionRun Time error Pin
monkeywrench1029-Sep-09 16:14
monkeywrench1029-Sep-09 16:14 
AnswerRe: Run Time error Pin
Cedric Moonen29-Sep-09 20:25
Cedric Moonen29-Sep-09 20:25 
GeneralRe: Run Time error Pin
monkeywrench1030-Sep-09 3:31
monkeywrench1030-Sep-09 3:31 
QuestionUsing an API Pin
Donguy197629-Sep-09 15:34
Donguy197629-Sep-09 15:34 
AnswerRe: Using an API Pin
Saurabh.Garg29-Sep-09 16:13
Saurabh.Garg29-Sep-09 16:13 
GeneralRe: Using an API Pin
dipuks30-Sep-09 3:39
dipuks30-Sep-09 3:39 
GeneralRe: Using an API Pin
Saurabh.Garg30-Sep-09 4:00
Saurabh.Garg30-Sep-09 4:00 
QuestionWrite and read the same file in the same C program? Pin
Razanust29-Sep-09 14:02
Razanust29-Sep-09 14:02 
I tried out this code. The problem is that for example I input "Book" to the file so it displays 4characters of the ASCII '1'.
If I enter a three letter word it displays that character three times?
Here is the code.


#include<stdio.h>
#include<conio.h>
#include<windows.h>

char d;
main()
{
{
FILE *ft;
ft=fopen("test.txt","w");
char ch;
while(ch=getche())
{
if (ch=='\r')
break;
putc(ch,ft);}
fclose(ft);
}
system("cls");
printf("Read?");
d=getch();
system("cls");
if(d=='y')
goto read;
read:{
FILE *fp;
fp=fopen("test.txt","r+");
char chr;
while(chr=fgetc(fp)!=EOF)
printf("%d",chr);
fclose(fp);
}

}



AnswerRe: Write and read the same file in the same C program? Pin
David Crow29-Sep-09 15:55
David Crow29-Sep-09 15:55 
Questionwhat other files can IE display if without software support? Pin
includeh1029-Sep-09 11:47
includeh1029-Sep-09 11:47 
AnswerRe: what other files can IE display if without software support? Pin
enhzflep29-Sep-09 12:03
enhzflep29-Sep-09 12:03 
AnswerRe: what other files can IE display if without software support? Pin
Saurabh.Garg29-Sep-09 14:19
Saurabh.Garg29-Sep-09 14:19 
GeneralRe: what other files can IE display if without software support? Pin
David Crow29-Sep-09 15:32
David Crow29-Sep-09 15:32 
GeneralRe: what other files can IE display if without software support? Pin
Saurabh.Garg29-Sep-09 15:37
Saurabh.Garg29-Sep-09 15:37 
GeneralRe: what other files can IE display if without software support? Pin
includeh1029-Sep-09 19:08
includeh1029-Sep-09 19:08 
GeneralRe: what other files can IE display if without software support? Pin
Saurabh.Garg29-Sep-09 19:14
Saurabh.Garg29-Sep-09 19:14 
QuestionWhy does upload/download change file size? Pin
includeh1029-Sep-09 9:21
includeh1029-Sep-09 9:21 
QuestionRe: Why does upload/download change file size? Pin
David Crow29-Sep-09 10:51
David Crow29-Sep-09 10:51 
AnswerRe: Why does upload/download change file size? Pin
includeh1029-Sep-09 11:19
includeh1029-Sep-09 11:19 
AnswerRe: Why does upload/download change file size? Pin
CPallini29-Sep-09 10:59
mveCPallini29-Sep-09 10:59 
GeneralRe: Why does upload/download change file size? Pin
includeh1029-Sep-09 11:35
includeh1029-Sep-09 11:35 
GeneralRe: Why does upload/download change file size? Pin
Saurabh.Garg29-Sep-09 14:21
Saurabh.Garg29-Sep-09 14:21 
QuestionINF and/or NAN (global) exception during debug Pin
Russell'29-Sep-09 3:38
Russell'29-Sep-09 3:38 
AnswerRe: INF and/or NAN (global) exception during debug [modified] Pin
Nishad S29-Sep-09 4:04
Nishad S29-Sep-09 4:04 
GeneralRe: INF and/or NAN (global) exception during debug Pin
Russell'29-Sep-09 4:25
Russell'29-Sep-09 4: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.