|
Hi,
I have loaded a bitmap image to a dialog. The exe memory is increased by 1MB. The memory remains the same after closing the dialog. How to clear this memory.
Thanks,
|
|
|
|
|
May be the cleanup jobs are not done fully like bitmap's DeleteObject()
|
|
|
|
|
I have tried with DeleteObject function,but still memory is not getting reduced.
|
|
|
|
|
You should unload the bitmap. Refer the way youd load the bmp.
Press F1 for help or google it.
Greetings from Germany
|
|
|
|
|
I am using LoadBitmap(nIDResource) to load image to dialog
|
|
|
|
|
will the CBitmap object get destroyed (or going out of scope)?
Press F1 for help or google it.
Greetings from Germany
|
|
|
|
|
Please show some code.
Regards,
Sandip.
|
|
|
|
|
Provided that you properly destroy the object, you don't have to worry about what Task Manager or similar tells you since it doesn't tell you what you think it does.
Read more here[^].
"It's supposed to be hard, otherwise anybody could do it!" - selfquote "High speed never compensates for wrong direction!" - unknown
|
|
|
|
|
If you are dynamically allocating memory from the C++ heap, the heap will generally not be reduced in size when that memory is freed. One alternative would be to directly allocate your own memory from windows using GlobalAlloc.
Anyone who thinks he has a better idea of what's good for people than people do is a swine.
- P.J. O'Rourke
|
|
|
|
|
Hi all,
I want to use pimstore.h and aygshell.h in application.
when i include these files in using class than number of errors comes as follows:
pimstore.h(2545) : error C2061: syntax error : identifier 'CEBLOB'
pimstore.h(5465) : error C3121: cannot change GUID for class 'Folder'
1>gt; c:\program files\microsoft sdks\windows\v6.0a\include\shldisp.h(1546) : see declaration of 'Folder'
aygshell.h(286) : error C2061: syntax error : identifier 'SIPSTATE'
1>gt;SMSpadDlg.cpp
please help me for this.
Thanks in advance.
To accomplish great things, we must not only act, but also dream;
not only plan, but also believe.
|
|
|
|
|
"_$h@nky_" wrote: when i include these files...
Exactly where did you include them?
"_$h@nky_" wrote: pimstore.h(2545) : error C2061: syntax error : identifier 'CEBLOB'
This seems self-explanatory. No definition for CEBLOB was found prior to line 2545 of pimstore.h .
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
I want to learn C++ to be able to program on game consoles (mostly PS2, PS3 and Wii, not 360 or XBox), do you need to learn different commands and libraries than under windows?
I mean, obviously MFC and the everything about displaying windows won't work, but what about the rest?
And is there a way to test and debug a game on a windows PC without having to burn it to disc and test it on the console every time?
Thanks.
|
|
|
|
|
Megidolaon wrote: I want to learn C++ to be able to program on game consoles (mostly PS2, PS3 and Wii, not 360 or XBox), do you need to learn different commands and libraries than under windows?
I suppose you've to use the proper development kit, for instance, PS3 possibly has it's own. But it's just a guess, since this morning I'm too lazy to google it for you.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
It is important to understand the language. I see 2 parts:
1. "pure" C++ language, as mathematical operations and working with memory and the powerful (and that why dangerous) pointer arithmetics.
2. working with libraries or frameworks to target devices.
The first is for at most all the same BUT the second differences for the platform. So the libraries are depending for what target you develop. There are also libraries with more or less portability available. Compare the QT with the MFC. Or the IE with the FF => and the Addons for it.
Press F1 for help or google it.
Greetings from Germany
|
|
|
|
|
Hi
In my Server and Client (CSocket) Vc++ MFC application , I want to send Server system time to Client and Set the Local time in Client
SetLocalTime( SYSTEMTIME );.is for setting the local time.
How can pass the SYSTEMTIME object through the socket.
So I send from server and receive in Client and assign it.
Thanks and Regards
Shakumar
shakumar
|
|
|
|
|
I would pass it as any other chunk of data, i.e.
CSocket mySocket;
SYSTEMTIME st;
mySocket.Send(&st, sizeof(st));
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Thanks for u'r Reply
I tried u’r suggestion , sending is ok but how to receive it and type cast in to SYSTEMTIME
I Receiving as
char ch[1020];
CString m_str;
int m_Count = this->Receive(ch,strlen(ch));
ch[m_Count] = '\0';
m_str.Format("%s",ch);
AfxMessageBox(m_str);
Thanks & Regards
Shakumar
shakumar
|
|
|
|
|
What about
SYSTEMTIME st;
Receive(&st,sizeof(st)); ?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Thanks pallini & sandip
Now its working
shakumar
|
|
|
|
|
You're welcome.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Try this..
const int iSize = sizeof(SYSTEMTIME)
char szTemp[iSize];
SYSTEMTIME dtTime;
memcpy(szTemp,&dtTime,iSize);
You can also directly send the struct as indicated by CPallini..
in client side after you receive
SYSTEMTIME dtTime;
memcpy(&dtTime,szTemp,sizeof(SYSTEMTIME));
I hope it helps..
Regards,
Sandip.
|
|
|
|
|
How to use GetForegroundWindow in service mode application in Vista operating system.
Domain , VC++.
Sathish.S
ya
|
|
|
|
|
Yeah, you're not going to be able to do that - look at this page[^], specifically the second paragraph, where it says:
Services cannot directly interact with a user as of Windows Vista. Therefore, the techniques mentioned in the section titled Using an Interactive Service should not be used in new code
It's all about the security, man....
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
Hi Friends,
I've created a FindBar using the deskband.
I want to assign hotkey to Findbar, so that when user press 'Ctrl+f' key the findbar popsup in IE.
How can I do that?
Please help me.
ritz1234
|
|
|
|
|
Hi,i don't know what is FindBar. but you can use PreTranslateMessage(MSG *pMsg) to get the keybord.
|
|
|
|