473,395 Members | 2,468 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

WNDCLASS: cbWndExtra

Hi,

Is this right?

1)if I register a WNDCLASS in witch set cbWndExtra to a value greater than
0, this means that every time I create a window of that class there will be
an extra amount of memory alocated.

2)I can put something into that extra memory.

If the two statements are correct:

How can I write and read from that extra memory.

Thank you
Karel Bruneel

Jul 19 '05 #1
3 5429
On Sat, 30 Aug 2003 19:36:19 GMT, "Karel Bruneel" <Ka***********@pandora.be> wrote:
Hi,

Is this right?

1)if I register a WNDCLASS in witch set cbWndExtra to a value greater than
0, this means that every time I create a window of that class there will be
an extra amount of memory alocated.
Not necessarily, but there's an extra amount of memory _available_ for
your use.
2)I can put something into that extra memory.
Yes.

But since every Win32 window has room for a user-defined pointer you
generally don't need to specify more storage.

It's a relic from 16-bit Windows.
(Note that there are many other ways to associate data with a window,
including (1) SetProp/GetProp, (2) dynamically generated window proc
stub, and (3) static association table.)

If the two statements are correct:

How can I write and read from that extra memory.


GetWindowLong, SetWindowLong.

Jul 19 '05 #2
On Sat, 30 Aug 2003 19:54:03 GMT, al***@start.no (Alf P. Steinbach) wrote:


I'm sorry, I didn't notice this was crossposted to [comp.lang.c++].

Karel: DON'T DO THAT.

Or else... ;-)

Jul 19 '05 #3
I thank all of you.
"Karel Bruneel" <Ka***********@pandora.be> schreef in bericht
news:T0*******************@phobos.telenet-ops.be...
Hi,

Is this right?

1)if I register a WNDCLASS in witch set cbWndExtra to a value greater than
0, this means that every time I create a window of that class there will be an extra amount of memory alocated.

2)I can put something into that extra memory.

If the two statements are correct:

How can I write and read from that extra memory.

Thank you
Karel Bruneel

Jul 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

32
by: August1 | last post by:
Hi, I'm beginning to approach Windows programming in C++. I've written a short application which is to do nothing more than demonstrate the Window style being used. The child windows are not...
6
by: Thomas Barth | last post by:
Hi, I'm new to windows programming and still reading a book about windows-programming with C++. I copied the following code from the book into my ide (Eclipse/CDT) to comprehend the code, but two...
0
by: dag | last post by:
Hi! I would like to do an overlap window, over my main window (of my application), with a Progress Bar. Exactly when I push a button of my application I want show a window, with a Progress bar,...
2
by: Dr. Laurence Leff | last post by:
How does not compile a Windows API and a Windows MFC program from the command line with Visual.net. (I can do the former, at least, with Visual Studio by creating a "Win32 Project.") However, I...
1
by: Sean Dudley | last post by:
I need to run an API call that requires a WNDCLASS. How do I construct this in c#? I want to use RegisterClass. See, I want to register a TrayNotifyWnd class, etc so when a window seeks to...
11
by: Tom Shelton | last post by:
Last night I was feeling a little bored and I happend to come across a bit of code I wrote way back in the VB5 days. This code, was a simple little windows application - but was created strictly...
2
by: Eric Lilja | last post by:
This complete program compiles just fine: void foo(int, int = 0); void foo(int a, int b) { (void)a; (void)b; } int
1
by: hesamjamei | last post by:
Hello!! I am just about to break my computer...... Is a Window Programming issue .....compiler errors are as below : 1>------ Build started: Project: Project 78, Configuration: Debug Win32...
1
by: ayan4u | last post by:
#include <windows.h> #include <time.h> #define WIDTH 320 #define HEIGHT 240 LRESULT CALLBACK WinProc(HWND, UINT, WPARAM, LPARAM); int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrev, LPSTR...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.