• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 165
  • Last Modified:

Run-time error 7

I have written many VB6.0 programs, which I have compiled and installed successfully, on my machine and others. I wanted to change the interface on a particular program,, and when I went to the IDE to make the change and I ran the program (before I made any changes)  I got a Run-time error '7': Out of memory.. The debug always puts me at line of code where I populate a textbox with a variable. The variable can have various lengths, but are not extremely long. In all the development I've done, this is a first time event for me.
0
leland_mansuetti
Asked:
leland_mansuetti
  • 2
  • 2
  • 2
  • +2
1 Solution
 
PaulHewsCommented:
That's new for me too.  However, the out of memory error is a very common error that often has nothing to do with the amount of memory being consumed.  

First off, reboot, since flaky behaviour sometimes goes away after a reboot.  
Secondly, are there any non-printable ASCII chars in the string?  A lot of controls on the form?  Some background might help.
0
 
leland_mansuettiAuthor Commented:
The program runs fine when compiled and installed. The problem is isoloated to the IDE. It was only when I went into the IDE to change some colors and locations of an object did the error occur. I then loaded other programs I have written, and without exception, each failed when the program code called for the population of a text box with a string variable. The variables range from one or two sentences t o a complete balance sheet that includes letters. numbers, and variables for a carriage return. Some of these programs are several years old and have, to this point, run just fine in the IDE when I tested them. I have rebotted several times. And, the ASCII characters that I've used have always printed, since they are only letters, numbers, dollars signs, or punctuation. One of the longer strings is 5421 bytes. Yes, there are a lot of controls on the form, but there are on all of the ofher programs as well.

When I click on the text property of each texts box, the name I've given the textbox is followed by two or three flattened circles (maybe machine code). Each time I click on the text property, the number of symbols behind the name increase and appear on the form in the textbox as black squares behind the text box name. I've never seen this before.
These programs (ancillaries for accounting textbooks) have been published and distributed through McGraw-Hill/Irwin Publishing to college and universities and have always passed their techinical analysis.

0
 
PaulHewsCommented:
Sounds like something in your Visual Studio install is corrupted.  Unfortunately the only suggestion I have for that would be to reinstall Visual Basic.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
EDDYKTCommented:
Do you have any add-in installed and loaded? If yes, try to uncheck them and try again
0
 
EDDYKTCommented:
Also check your

tools->options->general tab

don't set on break on all errors, set to break in class module or break on unhandled errors
0
 
_lv_Commented:
Check that particular form (program) with another IDE on the other computer (my guess is that that you'll have the same problem). Try re-inserting (deleting and inserting) all textboxes (and possibly all controls on that form) sequentially. At least this is quicker than reinstalling Visual Studio.
Also - have you installed the latest service pack? (just in case you don't):
http://msdn.microsoft.com/vstudio/downloads/updates/sp/vs6/sp6/default.aspx

0
 
leland_mansuettiAuthor Commented:
Hi Iv. I downloaded the latest service pack. No help with problem. I'm using SSTabs with 7 tabs. I deleted and replaced the text box on Tab(2) and the error message did not appear. However, I had forgotten to change the multline property from false to true. When I changed the multline property to True, the error returned. I set the multline properties to false on all of the textboxes in every tab and the error no longer occured. But now, of course, the textboxes do not display appropriately.

Does this provide any clues about the problem. If the problem is a corrupted VB6.0, would it still be corrupted after the download of the service pack?
0
 
_lv_Commented:
What version of "Microsoft Tab ActiveX control" you are using? (Click "About" of SStab contol in Properties Window). Should be Version 6 (SP6). Could be, that the problem is not
the Tab control, but the textbox itself (try putting some textboxes on a new form and set 'multiline' property of them to 'true').
0
 
DarthModCommented:
PAQed with no points refunded (of 500)

DarthMod
Community Support Moderator
0

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

  • 2
  • 2
  • 2
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now