Search:

Type: Posts; User: Adak

Search: Search took 0.13 seconds.

  1. Replies
    18
    Views
    5,745

    Shucks, I was hoping for a good...never mind. :p...

    Shucks, I was hoping for a good...never mind. :p :p

    You're welcome.
  2. Replies
    18
    Views
    5,745

    You need to add the & before any non-string...

    You need to add the & before any non-string variable that you scan in (unless it's a pointer already).



    for(i=0;i<n;i++)
    {
    fgets(s[i].name, sizeof(s[i].name), f);
    fscanf(f,"%d %f %f ...
  3. Replies
    18
    Views
    5,745

    Everywhere you declare a Stock struct in your...

    Everywhere you declare a Stock struct in your program, you need to have:

    struct Stock nameofStockInstance;

    The keyword "struct" is essential, and your compiler should be giving you multiple...
  4. Replies
    18
    Views
    5,745

    I have Pelles C, and Pelles C is for C only and...

    I have Pelles C, and Pelles C is for C only and Windows only.

    Please, before we waste any time on it, compile it with your C NOT YOUR C++ compiler, and then see what happens.

    And please, don't...
  5. Replies
    18
    Views
    5,745

    As the error shows, you're trying to write to a...

    As the error shows, you're trying to write to a location that is invalid.

    fflush(stdin), used to work (sort of), on some compilers, years ago. It was heavily used by Turbo C help files and example...
  6. Replies
    18
    Views
    5,745

    In C, the '\' (backslash char), is an escape...

    In C, the '\' (backslash char), is an escape char, so strings with one \ in them, need to be doubled:


    f = fopen("e:\final.txt", "w");

    should be:
    f = fopen("e:\\final.txt", "w");

    or more...
Results 1 to 6 of 6