Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

runtime error 202

250 views
Skip to first unread message

Frank Mikalsen

unread,
Mar 21, 1996, 3:00:00 AM3/21/96
to
Juan Jose Perez <jua...@ciberteca.es> wrote:

>Anybody knows what's this error, it appears when I call a function, at the
>Begin instruction!, I use this funcion in a lot of programs without problems,
>any hit?

It is stack overflow. Increase the stacksize
in the ProjectOptions.Link page, or rewrite
the application to use less stack.

Hope this helps,
Frank
--
// Frank Mikalsen, System developer, Medicom Systems, Norway
// Homepage: http://home.sol.no/frankm
// Author of ShareWare: SILENT PARTNER BACKUP SCREENSAVER v2.50
// Download: http://www.winsite.com/pc/win3/desktop/spbck250.zip


Juan Jose Perez

unread,
Mar 21, 1996, 3:00:00 AM3/21/96
to jua...@ciberteca.es
Anybody knows what's this error, it appears when I call a function, at the
Begin instruction!, I use this funcion in a lot of programs without problems,
any hit?

Where can I find a list of runtime errors?

TIA
________________________________________________
Juan Jose Perez
ciberteca de Madrid [Jua...@ciberteca.es]
General Peron, 32 Bajo [Madrid]

a

unread,
Mar 21, 1996, 3:00:00 AM3/21/96
to
test

Wolfgang Zehntner

unread,
Mar 21, 1996, 3:00:00 AM3/21/96
to
jua...@ciberteca.es (Juan Jose Perez) wrote:

> Anybody knows what's this error, it appears when I call a function, at the
> Begin instruction!, I use this funcion in a lot of programs without
> problems, any hit?
>
> Where can I find a list of runtime errors?
>

most of these errors are in a book called "Delphi Developers Guide".
Error 202 however is not there. I think it means "Stack overflow", caused
by too large local variables, or recursive procedures/functions.

hth
Wolfgang

## CrossPoint v3.1 ##

marc hoffman

unread,
Mar 23, 1996, 3:00:00 AM3/23/96
to
...we came in?
/------------------------------------------------------------------------\

j> Anybody knows what's this error, it appears when I call a function, at the
j> Begin instruction!, I use this funcion in a lot of programs without
j> problems, any hit?

202 is Stack Overflow.try to enlarge your stack segment, reduce local
variables or move them onto the heap.

j> Where can I find a list of runtime errors?

i think in the help file you can get to a list via the "RunError"
description. at least in BP7 you can.

cu
marc
/--------------------------------------------------------------------------\
|ma...@donut.de marc hoffman@2:2444/1234 ma...@arb-phys.uni-dortmund.de|
\--------------------------------------------------------------------------/
isn't this where...
## CrossPoint v3.1 ##


Duncan Murdoch

unread,
Mar 24, 1996, 3:00:00 AM3/24/96
to
n...@netvision.net.il (Nir Sofer) wrote:
>> Where can I find a list of runtime errors?
>
>I have the runtime errors list from my old Turbo Pascal 6.0
>i haven't found it in Delphi help.

It's in the main help file, but they forgot to index it. If you can
find a full text search utility (like the one included in Win95), you
can find the runtime errors list. Otherwise, you have to look in the
Language Guide (downloadable from Borland).

Duncan Murdoch

T. Roy

unread,
Mar 25, 1996, 3:00:00 AM3/25/96
to
Hi,

My question is really not about Delphi but more about conventions...

I came across this guideline in a Delphi manual :

DON'T use a function to return multiple values both through
the function result and via var parameters. This use may be
confusing to the reader of the program.

Sometimes, I use function results to return error codes and
parameters to modify specific contents. Isn't this used extensively in
predefined 'C' functions ?

What do you think ?

Is there links with information on general programming conventions and
conventions specific to Delphi ?

Thanks,

Tony

----------------------------------------------------------------------------
Tony Roy Tel : (506) 547-2145
Instructor - Computer Science Fax : (506) 547-2174
New Brunswick Community College e-mail : ro...@gov.nb.ca
Bathurst, NB, Canada
----------------------------------------------------------------------------


Nir Sofer

unread,
Mar 25, 1996, 3:00:00 AM3/25/96
to
Juan Jose Perez <jua...@ciberteca.es> wrote:

>Anybody knows what's this error, it appears when I call a function, at the

>Begin instruction!, I use this funcion in a lot of programs without problems,
>any hit?

Runtime error 202 is Stack Overflow Error.
You have probably used a lot of local variables in this function or in the
function
that call this function.
You can solve this problem by increasing the Stack Size in the project
options.


> Where can I find a list of runtime errors?

I have the runtime errors list from my old Turbo Pascal 6.0
i haven't found it in Delphi help.

Nir Sofer
n...@netvision.net.il

QPWPlatts

unread,
Mar 26, 1996, 3:00:00 AM3/26/96
to
Hi, Tony!

I agree with you completely - sometimes you DO need to return an error
code as the result of the function call, and return other values in var
parameters. The function declaration and header should be enough
information for the user to understand, IMO.

Ken Whiet

Mads Bondo Dydensborg

unread,
Mar 27, 1996, 3:00:00 AM3/27/96
to
In article <4j9r69$j...@newsbf02.news.aol.com> qpwp...@aol.com (QPWPlatts) writes:

> Path: diku.dk!news.uni-c.dk!newsfeed.sunet.se!news00.sunet.se!sunic!news.sprintlink.net!newsfeed.internetmci.com!in2.uu.net!newstf01.news.aol.com!newsbf02.news.aol.com!not-for-mail
> From: qpwp...@aol.com (QPWPlatts)
> Newsgroups: comp.lang.pascal.delphi.misc
> Date: 26 Mar 1996 17:30:33 -0500
> Organization: America Online, Inc. (1-800-827-6364)
> Lines: 8
> Sender: ro...@newsbf02.news.aol.com
> References: <4j6f5n$9...@darwin.nbnet.nb.ca>
> Reply-To: qpwp...@aol.com (QPWPlatts)
> NNTP-Posting-Host: newsbf02.mail.aol.com

Couldn't you handle it with exceptions instead?

Mads
--
+---------------------------------------------------------------------+
| Mads Bondo Dydensborg. Student at DIKU, Copenhagen - Denmark. |
| Email: mad...@diku.dk www: http://www.diku.dk/students/madsdyd |
+---------------------------------------------------------------------+

Catherine Rees-Lay

unread,
Mar 28, 1996, 3:00:00 AM3/28/96
to
In article <4j6f5n$9...@darwin.nbnet.nb.ca>, "T. Roy" <ro...@gov.nb.ca>
writes
What I was taught (admittedly in Fortran, but subroutines/functions are
pretty much equivalent to procedures/functions) was that this defines
when you should use a subroutine rather than a function, i.e. if you
want to return more than one thing you should not use a function. This
is the concept of a "safe" function as one which doesn't modify its
arguments.

I wouldn't say that modifying an argument to a function is unclear, more
that if you never do it then if on coming back to a piece of code n
months later you see "x := func(lots of arguments)" you know instantly
that you don't have to worry about the arguments' return values
changing. Makes your code easier to understand in the long run - to
yourself as well as others.

However, your specific situation of returning an error code as the
function value strikes me as a case where it would be clear what was
going on. Personally I find this a lot less confusing than a function
which returned the value, and an error code in one of the arguments.

Catherine.
Catherine Rees-Lay Cath...@polyhdrn.demon.co.uk
Polyhedron Software Ltd.
Programs for Programmers - QA, Compilers, Graphics
************ Visit our Web site on http://www.polyhedron.co.uk/ ************

David Appleton

unread,
Mar 31, 1996, 3:00:00 AM3/31/96
to
In article <4j6f5n$9...@darwin.nbnet.nb.ca>, "T. Roy" <ro...@gov.nb.ca>
writes
>Hi,
>
> My question is really not about Delphi but more about conventions...
>
> I came across this guideline in a Delphi manual :
>
> DON'T use a function to return multiple values both through
> the function result and via var parameters. This use may be
> confusing to the reader of the program.
>
>Sometimes, I use function results to return error codes and
>parameters to modify specific contents. Isn't this used extensively in
>predefined 'C' functions ?
>
> What do you think ?
>
Ada is often regarded as the "Software Engineers" language (No flames on
this please - I KNOW that is a contentious statement but I have put
"often") and Ada does not allow the use of a var ( Ada => in | in out )
parameter to a function.

However the exception model in Ada is fairly well developed (it can be
improved) and this is the usual way to return a status code of
"unexpected error" from a function.

However all Ada guidelines state quite clearly that a program that
"relies on exceptions for normal operation" should be regarded as
erroneous.

Therefore a function that (for example) performs a directory search for
a file should only return an exception if an error such as "disk error"
were to occur. An error of "file not found" would not normally be
regarded as an exceptional condion (unless you had just put it there!)
and hence a difference mechanism should be used.

So in the latter case either:

a) A procedure with two out parameters (file name, error code)

b) A function, returning some form of record containing file
details and status code.

Of the two I prefer b) if use an OO type method for analysis and design.
This would seem to imply that often an object approach would lead to a
function with an object as a return.

However on top of this (or under maybe) is MS Windows for Delphi
Programmers. This does not use the OO type of model and hence the
question, as I see it, is where the line is drawn between the non OO
approach of MS and the OO approach of Delphi.

Probably now back to square one - but I shall be interested in the views
of others.
--
David Appleton

Halvari

unread,
Apr 1, 1996, 3:00:00 AM4/1/96
to
How can I include bitmaps, icons etc into a DLL and how do I use it in a
Delphi-program? Is it the resourcefile that is included in the DLL? Is
there some literature that handles DLL in detail?

Thanks

Svein Dybvik

O.A.Halvari AS
email : svein....@oahalvari.telemax.no


QPWPlatts

unread,
Apr 3, 1996, 3:00:00 AM4/3/96
to
Hi, Mads -

Of course you could handle it with an exception (and should if it is
something critical). The error codes I was referring to were non-critical
types of errors (like requesting a read of <x> bytes from a binary file
into a var buffer, and returning the number of actual bytes read). This
doesn't necessarily indicate an exception-type error, but could indicate
that you've reached the end of the file...

I heartily agree that for critical errors you should raise an exception!

Ken

0 new messages