Re: A89: Re: A Address book With Some Real Problems
[Prev][Next][Index][Thread]
Re: A89: Re: A Address book With Some Real Problems
At 8/23/00 06:12 AM, you wrote:
>Oh boy, this is gonna be fun. It's 5:30 AM and I can't resist:...
I'm sure
>(4) no code doing it as you are will ever compile.
It does and it works fine.
>(5) Most of your variables do not need to be globals.
one of the things that one will learn from this is that this is just
getting it working, and i believe that if you want to use globals, you can,
at this point, how do you know that i will not use them later in the code
in a different function?
>(6)
ok, thanks
>(7) "Magic numbers" - that is, hardcoded constants - are bad.
why?
>(8) > return 0;
why not? i believe that it is a style thing, makes all functions look
neater , unless you can give me a reason why it is bad to do, i will keep
doing it
>(9) > while(result!=0&&result!=9)
>Were you to fix up your syntax errors so that the code will actually run,
>you'd see that result will never be see to either of those values when
>encountering this pretest, and thus the loop is infinite.
If you would actually run the code, you will see that, not only does this
work, but that it is the best way to do it that i could do really fast. do
you know what while does? it runs the loop WHILE result!= 0 or 9, i.e. if
the user presses esc, it sets result to 0 and if the user uses the quit
function, it sets result to 9 and ends the loop.
> > Also, how can i disable the help messages when i call a dialog, ie i
> want to disp my own instead of the use the arrow keys and enter or esc
> stuff. Any help would be welcomed.
>Use a callback routine. I'm not sure how much of that has been
>documented, so I'll leave that to Zelkjo to answer if he so chooses in
>order to avoid saying anything I shouldn't. But you shouldn't even be
>THINKING about doing this yet.
why not? and what is this callback function?
Rob Smith
----
Stupidity got us into this mess - why can't it get us out?
Proud member of:
* <http://pa.ticalc.org>Programmers Anonymous
* <http://www.tigalaxy.com>TIGALAXY
* <http://c489.tigalaxy.com>C489
* <aim:addbuddy?screenname=Billvortex>Add Me To Your AIM Buddy List
References: