0

I am trying to write a program to print a file to a printer.

havent gotten fery far till I started to go ary, here is the listing so far.

// This Program is to print a file listing with line numbers to Printer.
#include <stdlib.h>
#include <stdio.h>
#include <conio.h>
int line = 0, page = 0;
   
int main( int argv, char *argc[] )
{
    char buffer[256];
    FILE *fp;
    printf("Enter File Name.\n ");
    
    scanf("filename.ext" );
    
    printf("%d",filename.ext "\n" );
    
    system( "PAUSE" );
    
    return 0;
}

I'm thinking that the SCANF is not capturing the filename.ext thier for

ofcourse it will not print is the following statement.

any assistance would be greatly Appreciated.

Thank you

Dick

3
Contributors
4
Replies
8
Views
11 Years
Discussion Span
Last Post by WaltP
0

it is to capture input of a filename & extention
from the keyboard.

Dick

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.