From: "Eric" Newsgroups: comp.os.msdos.djgpp Subject: unable to assign or initialize variables - HELP Date: Tue, 10 Feb 1998 12:01:36 -0500 Organization: MindSpring Enterprises Lines: 42 Message-ID: <6bq161$el6@camel18.mindspring.com> NNTP-Posting-Host: ip203.garden-city4.ny.pub-ip.psi.net To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk The following line: scanf("%d-%d-%d-%c", &beg_X, &end_Y, &wColor, &ch); will NOT assign a value to the first variable (&beg_X) and it remains at zero. BUT IF I FLIP the order of the first two variable (ie, scanf("%d-%d-%d-%c", &end_Y, &beg_X, &wColor, &ch);), VALUES ARE ASSIGNED! In a similar vein, the following line: WORD left = 8, top = 10, right = 50, bottom = 20, type; will properly initialize evry requested variable of type word EXCEPT FOR THE last one (bottom = 20). I had to reassign the value later in the code. I'm using RHIDE on a Windows 95 machine. Any help much appreciated. begin 666 ATT00066.gif M1TE&.#EA% `4`/<``/______S/__F?__9O__,___`/_,___,S/_,F?_,9O_, M,__,`/^9__^9S/^9F?^99O^9,_^9`/]F__]FS/]FF?]F9O]F,_]F`/\S__\S MS/\SF?\S9O\S,_\S`/\`__\`S/\`F?\`9O\`,_\``,S__\S_S,S_F+#BA8CDLAX<2-'C1]!AFSH<20`C"%1?E3)D65&EQ9A4BPY4B9$ '@SAS!@0`.P`` ` end