User Profile

Collapse

Profile Sidebar

Collapse
janes
janes
Last Activity: Dec 28 '11, 04:56 AM
Joined: Dec 22 '11
Location: school
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • janes
    replied to how to use the struct in C
    in C
    Oh, I solved the problem by johny, I have a little opinion about the using of the keyword struct. I think the struct verb is the new data struct by yourself, that you can't put definition of the struct in the program file, or the compile machine say the struct is not define, so, you can not do this like use int, char or other data struct that define in c compile. That in other C file is already know the int or char data struct, so you can int a in...
    See more | Go to post

    Leave a comment:


  • janes
    replied to how to use the struct in C
    in C
    Thank you, I think I am a new man, I want you tell me how can I define struct verb in test.h,may is define extern struct image ss in the test.h. That struct image{
    int a;
    char b;
    }; in test.c
    I do this but failed!
    Thank you, Thank you!
    See more | Go to post

    Leave a comment:


  • janes
    started a topic how to use the struct in C
    in C

    how to use the struct in C

    I create two C files, one is main.c and another is test.c,and then I defined an struct verb in test.c:
    struct image{
    int a;
    char b;
    };
    struct image ss;

    void test() {
    ss.a = 10;
    }
    I want to use the struct verb ss in the main.c,but I failed. Please help me how can I use the struct verb ss in the main.c.
    Thank you very much
    See more | Go to post
No activity results to display
Show More
Working...