From: "Andy Kilner" Newsgroups: comp.os.msdos.djgpp Subject: Re: array subscript error Date: Fri, 19 Mar 1999 14:32:05 -0000 Organization: Customer of Planet Online Lines: 17 Message-ID: <7ctn0s$fku$1@newsreader2.core.theplanet.net> References: <7crlk8$57p$1 AT newsreader3 DOT core DOT theplanet DOT net> NNTP-Posting-Host: modem82.scully.kingston-internet.net X-Trace: newsreader2.core.theplanet.net 921853788 16030 195.92.234.210 (19 Mar 1999 14:29:48 GMT) NNTP-Posting-Date: 19 Mar 1999 14:29:48 GMT X-Complaints-To: abuse AT theplanet DOT net X-Newsreader: Microsoft Outlook Express 4.72.3110.5 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com the error is in the line: return buffer[cury][curx]->ch; buffer* is a buffer for a window on the screen, the window is an instance of a class defining the position and size of the window on screen. I am just trying to declare a dynamic array as the window can be of any size So, buffer[cury][curx] should give me the screen_ch at the current cursor position on screen and therefore, buffer[cury][curx].ch should give the character at the current position. (the ->ch I wrote on my original post was wrong but the error is still the same). Thanks Andy