Re: Error in Object [message #46049] |
Thu, 03 November 2005 18:32  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
shi_lee@hotmail.com writes:
> thank you Dr.Fanning, could you explain in a little more detail. I am
> pretty unfamiliar with this area. Should I switch oview with state when
> passing the parameters? I tried, but still does not work. Thanks.
Well, obviously, I can't tell exactly what you are doing
wrong without examining the code (and I don't examine code,
as a rule, unless someone is forking over some money), but
from the kind of errors you were getting it is clear that
you don't have what you think you have. I thought there
was a reasonably good chance you had confused one variable
with another.
I think you should learn how to set breakpoints in your
code so that you can stop and examine variables yourself.
This is a standard programming practice and everyone should
know how to do it. I've been teaching a beginning programming
class this week, and you have to hammer on some of these people
to even look at the error message so they know what line in
their program caused the error! (And I swear some of the antique
text editors they use don't even have a way to go to the line
that caused the error! Sheesh! It's like trying to hit a tennis
ball blindfolded.)
But, that is neither here nor there. Just poke around in
there until you understand what is going on. I did get a
sense that maybe you were a little inexperienced in this
business. Object graphics code is probably not the best
place to start learning, under the circumstances. Is there
a particular reason you have started there?
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
|
|
|