"Error Message - tried to execute invalid instruction"

Please support our C++ advertiser: Intel Parallel Studio Home
Reply

Join Date: Sep 2004
Posts: 1
Reputation: Sandra John is an unknown quantity at this point 
Solved Threads: 0
Sandra John Sandra John is offline Offline
Newbie Poster

"Error Message - tried to execute invalid instruction"

 
0
  #1
Sep 5th, 2004
Hello !

I am using Turbo C++ compiler and I am trying to implement Dictionary using arrays. All my menu options work perfectly but finally when I give exit option the program comes out of Turbo C++ and gives a window saying
"The program tried to execute an invalid instruction "
"Fault Location : 6172 : 74E6"
and the MS-DOS window closes.

Can you help me trouble shoot this problem ?

Sandra John
Attached Files
File Type: cpp Dic.cpp (8.4 KB, 4 views)
File Type: h Dic_arr.h (5.7 KB, 1 views)
Reply With Quote Quick reply to this message  
Join Date: Jun 2004
Posts: 436
Reputation: Chainsaw is an unknown quantity at this point 
Solved Threads: 11
Chainsaw's Avatar
Chainsaw Chainsaw is offline Offline
Unprevaricator

Re: "Error Message - tried to execute invalid instruction"

 
0
  #2
Sep 5th, 2004
It looks like you used to 'break' but now just return 1. I take it that the break failed as well?

I'd look more closely at the dictionary destructor. It sure looks simple, but maybe something there has gone astray.

There's no return from main, and main doesn't have the argv[], argc parameters; is that ok in turbo C?

Doesn't turbo C have a debugger you could set a breakpoint at the case for 6 and step line by line (step IN) to see where it fails?
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the C++ Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC