Connecting Tech Pros Worldwide Help | Site Map

Windows Error at run-time...

  #1  
Old July 22nd, 2005, 05:44 PM
Reimar Twelker
Guest
 
Posts: n/a
Hi there,
I'm learning OpenGL and unfortunately I am also new to C++...
My problem is that I am not used to pointers (yet) and my little app
always crashes at run-time...access violation of some sort.

The windows message reads:
....the expression <memory address> points to <0x00000000>. The process
'written' could not be executed...

I have been trying to fix this for a few days now and I NEED HELP!

....I don't have to tell you that I don't know ANYTHING about debugging
in Visual C++ ...:)

I think that my problem is caused by some sort of NULL-pointer I am
writing...
By the way: I have written a class and when I try to create an
instance, my app doesn't even create an application window but crashes
on the spot. I came across this (new?) problem when I tried to avoid
using pointers :| Maybe something is wrong with my class definition
but I'm not new to OOP, I have been using Java for quite some time...

Thanx in advance!!
Reimar
  #2  
Old July 22nd, 2005, 05:44 PM
Victor Bazarov
Guest
 
Posts: n/a

re: Windows Error at run-time...


Reimar Twelker wrote:[color=blue]
> I'm learning OpenGL and unfortunately I am also new to C++...[/color]

The two are relatively orthogonal. You can learn C++ without learning
OpenGL and vice versa.
[color=blue]
> My problem is that I am not used to pointers (yet) and my little app
> always crashes at run-time...access violation of some sort.
>
> The windows message reads:
> ...the expression <memory address> points to <0x00000000>. The process
> 'written' could not be executed...
>
> I have been trying to fix this for a few days now and I NEED HELP![/color]

What kind of help do you expect? Perhaps you should start by reading
the FAQ: http://www.parashift.com/c++-faq-lite/
[color=blue]
>
> ...I don't have to tell you that I don't know ANYTHING about debugging
> in Visual C++ ...:)[/color]

You don't need to know anything about debugging in Visual C++ to be
a decent C++ programmer.
[color=blue]
>
> I think that my problem is caused by some sort of NULL-pointer I am
> writing...[/color]

Yes, looks like it.
[color=blue]
> By the way: I have written a class and when I try to create an
> instance, my app doesn't even create an application window but crashes
> on the spot. I came across this (new?) problem when I tried to avoid
> using pointers :| Maybe something is wrong with my class definition
> but I'm not new to OOP, I have been using Java for quite some time...[/color]

When you have pointer problems like the one you described, it is most
likely in the implementation, not necessarily in the class definition.

By the way: what C++ book are you using to learn?

V
  #3  
Old July 22nd, 2005, 05:44 PM
John Harrison
Guest
 
Posts: n/a

re: Windows Error at run-time...


On 21 Jul 2004 13:58:44 -0700, Reimar Twelker <existenzquantor@gmx.de>
wrote:
[color=blue]
> Hi there,
> I'm learning OpenGL and unfortunately I am also new to C++...
> My problem is that I am not used to pointers (yet) and my little app
> always crashes at run-time...access violation of some sort.
>
> The windows message reads:
> ...the expression <memory address> points to <0x00000000>. The process
> 'written' could not be executed...
>
> I have been trying to fix this for a few days now and I NEED HELP!
>
> ...I don't have to tell you that I don't know ANYTHING about debugging
> in Visual C++ ...:)[/color]

Visual C++ has an excellent and intuitive debugger, learning how to use it
would probably be the quickest way of solving your problem. Look on it as
an opportunity.
[color=blue]
>
> I think that my problem is caused by some sort of NULL-pointer I am
> writing..[/color]

Seems plausible.
[color=blue]
> By the way: I have written a class and when I try to create an
> instance, my app doesn't even create an application window but crashes
> on the spot. I came across this (new?) problem when I tried to avoid
> using pointers :| Maybe something is wrong with my class definition
> but I'm not new to OOP, I have been using Java for quite some time...
>[/color]

In the absence of any code it's very hard to help. Please post the
smallest program you can that has this problem.

Also please note that OpenGL is not on topic in this group. If you program
is stuffed full of OpenGL code or if the problem is something to do with
the way you are using OpenGL then you would be better off asking your
question elsewhere (not sure where tho').

Perhaps you could read this group's welcome message first, to get an idea
of what this group is about.

http://www.slack.net/~shiva/welcome.txt

john
  #4  
Old July 22nd, 2005, 05:44 PM
JKop
Guest
 
Posts: n/a

re: Windows Error at run-time...



You're problem here is that you didn't post code.


-JKop
  #5  
Old July 22nd, 2005, 05:46 PM
Reimar Twelker
Guest
 
Posts: n/a

re: Windows Error at run-time...


Hi again,
sorry, that I didn't post any code yesterday, hard to give advice
without having anything to think about...OK, I used (I actually
clicked here and there...) the VC++ Debugger and voila!...
problem solved...I hope it lasts:)

Some of my pointers were bad...

Thanks all!
Reimar
Closed Thread


Similar Threads
Thread Thread Starter Forum Replies Last Post
Error in displaying records in GridView =?Utf-8?B?SmFjaw==?= answers 1 June 27th, 2008 09:14 PM
Microsoft SQL 2005 Server Express Edition Install Error silviu answers 0 November 22nd, 2007 08:36 PM
Error at constructor for SqlConnection RvGrah answers 2 January 9th, 2007 09:35 PM
Error at runtime in JDK 1.5.0_9 (J2SE) Radster answers 2 November 14th, 2006 06:26 PM
Error at a Query about more than one Tables (with ODBC) Bibi answers 2 November 13th, 2005 06:12 AM