Click here to Skip to main content
15,915,094 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionHow to generate Crystal Report in VC++ (VS2008) Pin
shiokbarnabas12-Aug-12 18:00
shiokbarnabas12-Aug-12 18:00 
AnswerRe: How to generate Crystal Report in VC++ (VS2008) Pin
Software_Developer12-Aug-12 23:18
Software_Developer12-Aug-12 23:18 
QuestionRichedit is displayed and Immediately aborts Pin
ForNow11-Aug-12 17:53
ForNow11-Aug-12 17:53 
AnswerRe: Richedit is displayed and Immediately aborts Pin
Richard MacCutchan11-Aug-12 21:44
mveRichard MacCutchan11-Aug-12 21:44 
GeneralRe: Richedit is displayed and Immediately aborts Pin
ForNow12-Aug-12 3:07
ForNow12-Aug-12 3:07 
GeneralRe: Richedit is displayed and Immediately aborts Pin
Richard MacCutchan12-Aug-12 4:01
mveRichard MacCutchan12-Aug-12 4:01 
GeneralRe: Out of Memory help Pin
ForNow12-Aug-12 12:47
ForNow12-Aug-12 12:47 
GeneralRe: Out of Memory help Pin
Bram van Kampen12-Aug-12 14:45
Bram van Kampen12-Aug-12 14:45 
Hi,


ForNow wrote:
1) How can I tell how much heap storage is allocated to my app


1) Derrive All classes from a common abstract class. 'MyCommonClass'
2) Declare a Static property: 'QWORD MyCommonClass::m_qw_AllocMem=0;'
3) Declare a Pure Virtual Function 'DWORD MyCommonClass::_GetSize()=0'
4) Write a Contructor:'MyCommonClass::MyCommonClass(){m_qw_AllocMem+=_GetSize();}'
5) Write a Destructor:'MyCommonClass::~MyCommonClass(){m_qw_AllocMem-=_GetSize();}'



ForNow wrote:
2) Is there anyway from the Visual Studio debugger to tell how much heap I have
used
 


Well I'm using C++ 5.00, and, No, there is none there.
ForNow wrote:
The only information I have is from task manager in the memory coulmn (private
working set) says I am using 2,540 for my process
 
My laptop has
3.00 gb I think I could go up to 4 gb though I don't think adding more memory is
the root of the problem
 


Well I dont'know what you are trying to achieve. I take it that you've only one thread. Also, you will get the same message if you exhaust the stack. This can happen if you have an Not Terminating recursion. (A recursion is a routine calling itself)

A 'RichEdit' is not an easy control to set up. It relies on COM Objects to do its bidding. I have always avoided this control for that reason. COM objects, by their nature are linked at Runtime, the details of the actual DLL and Function to be called extracted from the Registry. That latter process is notoriouisly slow, and consumes large amounts of memory.

Also, some libaries simply report 'Out Of Memory' when any other error occurs, which the author did not document further.

Hope this was usefull,
Bram van Kampen Smile | :)

QuestionRe: Out of Memory help Pin
Richard Andrew x6412-Aug-12 15:12
professionalRichard Andrew x6412-Aug-12 15:12 
AnswerRe: Out of Memory help Pin
Bram van Kampen13-Aug-12 11:24
Bram van Kampen13-Aug-12 11:24 
GeneralRe: Out of Memory help Pin
Richard Andrew x6413-Aug-12 12:10
professionalRichard Andrew x6413-Aug-12 12:10 
GeneralRe: Out of Memory help Pin
Richard MacCutchan12-Aug-12 21:44
mveRichard MacCutchan12-Aug-12 21:44 
GeneralRe: Out of Memory help Pin
ForNow13-Aug-12 2:56
ForNow13-Aug-12 2:56 
GeneralRe: Out of Memory help Pin
Richard MacCutchan13-Aug-12 3:02
mveRichard MacCutchan13-Aug-12 3:02 
GeneralRe: Out of Memory help Pin
ForNow13-Aug-12 7:01
ForNow13-Aug-12 7:01 
GeneralRe: Richedit is displayed and Immediately aborts Pin
VINSON_13-Aug-12 20:54
VINSON_13-Aug-12 20:54 
GeneralRe: Richedit is displayed and Immediately aborts Pin
Richard MacCutchan13-Aug-12 21:26
mveRichard MacCutchan13-Aug-12 21:26 
QuestionCSplitterWnd::GetPane asserts with CFormView pane Pin
Vaclav_11-Aug-12 5:14
Vaclav_11-Aug-12 5:14 
AnswerRe: CSplitterWnd::GetPane asserts with CFormView pane Pin
Stephen Hewitt11-Aug-12 7:28
Stephen Hewitt11-Aug-12 7:28 
Questionhow to reference a c# DLL from a c++ DLL Pin
gs_murphy@ntlworld.com10-Aug-12 2:55
gs_murphy@ntlworld.com10-Aug-12 2:55 
AnswerRe: how to reference a c# DLL from a c++ DLL Pin
Software_Developer10-Aug-12 4:21
Software_Developer10-Aug-12 4:21 
AnswerRe: how to reference a c# DLL from a c++ DLL Pin
Richard MacCutchan10-Aug-12 21:42
mveRichard MacCutchan10-Aug-12 21:42 
QuestionHelp! Crystal Report for VC++ project (VS2008) Pin
shiokbarnabas9-Aug-12 17:11
shiokbarnabas9-Aug-12 17:11 
AnswerRe: Help! Crystal Report for VC++ project (VS2008) Pin
_Flaviu9-Aug-12 19:09
_Flaviu9-Aug-12 19:09 
GeneralFunction to pointer problem Pin
_Flaviu9-Aug-12 7:49
_Flaviu9-Aug-12 7:49 

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.