Click here to Skip to main content
14,302,396 members
   

C#

 
AnswerRe: Getting Exception Window Class Name is not Valid in Windows Application using vb.net Pin
Eddy Vluggen17-Jul-19 13:51
mveEddy Vluggen17-Jul-19 13:51 
AnswerRe: Getting Exception Window Class Name is not Valid in Windows Application using vb.net Pin
phil.o17-Jul-19 22:13
mvephil.o17-Jul-19 22:13 
AnswerRe: Getting Exception Window Class Name is not Valid in Windows Application using vb.net Pin
Richard Deeming17-Jul-19 22:52
mveRichard Deeming17-Jul-19 22:52 
QuestionOutOfMemoryException help please Pin
DTGeek17-Jul-19 5:07
memberDTGeek17-Jul-19 5:07 
AnswerRe: OutOfMemoryException help please Pin
OriginalGriff17-Jul-19 5:21
protectorOriginalGriff17-Jul-19 5:21 
AnswerRe: OutOfMemoryException help please Pin
Gerry Schmitz17-Jul-19 6:07
mveGerry Schmitz17-Jul-19 6:07 
GeneralRe: OutOfMemoryException help please Pin
DTGeek17-Jul-19 6:11
memberDTGeek17-Jul-19 6:11 
AnswerRe: OutOfMemoryException help please Pin
Luc Pattyn17-Jul-19 7:42
professionalLuc Pattyn17-Jul-19 7:42 
Hmm.

Great puzzle. "Doctor I'm ill" without any detailed symptoms.

Nevertheless I've been looking for the most common sources of OutOfMemoryException:
- properties that get or set themselves recursively; I did not see any user-defined Property.
- functions that call themselves recursively; I did not see any of them (I may have missed one though).

The next suspect would be event handlers that modify something causing ever more events, possibly resulting in an avalanche. Without any description of this beast, that is hard to find.

I have some more comments though:

1.
I see a lot of new Font statements; most if not all of them only generate two different fonts, so I suggest you generate them once, keep them around in two variables, and assign them to a local variable as appropriate.

Now whenever that approach would be impossible, keep in mind that objects offering a Dispose method require that method being called when done to free up unmanaged data; and most graphic objects (including Font) fall in that category.

2.
And now for a big issue:
you are swallowing exceptions; there are lots of try/catch blocks, and yes they always store the exception message (why only the message?) but then that magic secondLevelMsg variable is never looked at??? The author of this is making life extremely hard, exceptions are there to help you in finding what is going wrong. The current code is very good at hiding what might go wrong. Also, exceptions should not be used as the normal way out. Their occurence should be, well, exceptional.

Hope this helps.

Smile | :)
Luc Pattyn [My Articles] Nil Volentibus Arduum

GeneralRe: OutOfMemoryException help please Pin
DTGeek17-Jul-19 8:17
memberDTGeek17-Jul-19 8:17 
GeneralRe: OutOfMemoryException help please Pin
Luc Pattyn17-Jul-19 8:20
professionalLuc Pattyn17-Jul-19 8:20 
GeneralRe: OutOfMemoryException help please Pin
Luc Pattyn17-Jul-19 12:53
professionalLuc Pattyn17-Jul-19 12:53 
AnswerRe: OutOfMemoryException help please Pin
Eddy Vluggen17-Jul-19 13:50
mveEddy Vluggen17-Jul-19 13:50 
QuestionQuick Question - Data Validation Range with DateTime Pin
Kevin Marois16-Jul-19 7:05
professionalKevin Marois16-Jul-19 7:05 
AnswerRe: Quick Question - Data Validation Range with DateTime Pin
OriginalGriff16-Jul-19 8:16
protectorOriginalGriff16-Jul-19 8:16 
AnswerRe: Quick Question - Data Validation Range with DateTime Pin
Richard Deeming16-Jul-19 9:15
mveRichard Deeming16-Jul-19 9:15 
AnswerRe: Quick Question - Data Validation Range with DateTime Pin
BillWoodruff16-Jul-19 20:34
mveBillWoodruff16-Jul-19 20:34 
AnswerRe: Quick Question - Data Validation Range with DateTime Pin
Eddy Vluggen16-Jul-19 23:22
mveEddy Vluggen16-Jul-19 23:22 
GeneralRe: Quick Question - Data Validation Range with DateTime Pin
BillWoodruff17-Jul-19 0:43
mveBillWoodruff17-Jul-19 0:43 
GeneralRe: Quick Question - Data Validation Range with DateTime Pin
Eddy Vluggen17-Jul-19 1:09
mveEddy Vluggen17-Jul-19 1:09 
GeneralRe: Quick Question - Data Validation Range with DateTime Pin
OriginalGriff17-Jul-19 2:49
protectorOriginalGriff17-Jul-19 2:49 
GeneralRe: Quick Question - Data Validation Range with DateTime Pin
Eddy Vluggen17-Jul-19 13:53
mveEddy Vluggen17-Jul-19 13:53 
AnswerRe: Quick Question - Data Validation Range with DateTime Pin
Gerry Schmitz17-Jul-19 6:15
mveGerry Schmitz17-Jul-19 6:15 
Questionhow I input Hebrew from winForm to mySql Pin
Member 1387299916-Jul-19 0:17
memberMember 1387299916-Jul-19 0:17 
AnswerRe: how I input Hebrew from winForm to mySql Pin
OriginalGriff16-Jul-19 0:36
protectorOriginalGriff16-Jul-19 0:36 
GeneralRe: how I input Hebrew from winForm to mySql Pin
Member 1387299916-Jul-19 0:54
memberMember 1387299916-Jul-19 0:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.