|
WM_COMMAND is message id. WM_COMMAND is sent in response to menu selections, accelerator keys being pressed and some events in controls like edit boxes. wParam contains the command id/control id.
message id != command id.
Tomasz Sowinski -- http://www.shooltz.com
"Yields falsehood when preceded by its quotation" yields falsehood when preceded by its quotation.
|
|
|
|
|
Thanks Tomasz,
I feel bemused by the fact that I couldn't find such a seemingly basic concept in the MSDN... do you know where such a thing would be documented? The MSDN page on CWnd.SendMessage() just says that wParam depends on the command being sent--nothing more.
I would be interested to understand the messaging better.
Thanks!
JennyP
|
|
|
|
|
JennyP wrote:
The MSDN page on CWnd.SendMessage() just says that wParam depends on the command being sent--nothing more.
Sorry, it says that wParam depends on MESSAGE being sent, not command. You should understand the difference if you want to succeed in developing software for Windows.
Tomasz Sowinski -- http://www.shooltz.com
"Yields falsehood when preceded by its quotation" yields falsehood when preceded by its quotation.
|
|
|
|
|
If I have mp3 data reside in memory, can I play mp3 data using DirectShow?
If can't play by DirectShow, how can I play it?
|
|
|
|
|
Does anyone know, why metafiles work extremly slow for graphical filled objects in W2K?
I have a small app, which works fast on WindowsNT 4.0 and Windows XP but it slows down during META_CREATEREGION on Win2K.
|
|
|
|
|
Hi All,
I need to develop an COM Component in VC++ that would put up an entry in the NT application log if the application encounters some error.How do I develop such a COM Component.Is there any method.Please help.
Thanks
Abhishek.
Learning is a never ending process of Life.
|
|
|
|
|
See at WFC Library (CEventLog).
Sonork 100.15206;PavelK
|
|
|
|
|
Hi,
How can I detect an application instance..whether its already running or not?
I am running an application now I want that if that application is running then if I double click that application icon then it should popup the currently running application instance in place of opening a new instance.
Is it possible to detect application instance in VC6?
Thanks in advance
Prateeti
|
|
|
|
|
|
any one try to dev. firewall ?
i need any info about how to write firewall applicatioin
|
|
|
|
|
|
Suppose we execute a SQL query that returns various fields. Now in order to get value of certain field we use following methods:
vtField = pRecordset->Fields->GetItem("Name")->Value;
OR
vtField = pRecordset->GetCollect("Name");
But there are certain queries that do not return any field but a single value e.g
select count(userid) from mytable
Suppose i execute this query and its result is in RecordSet object. Now how can i retrieve this value as this is a single value and is not represented by any field ????
|
|
|
|
|
Try
select count(userid) as count from mytable
vtField = pRecordset->GetCollect("count");
Todd Smith
|
|
|
|
|
How can I do decimal precision in an edit control? For example, .002 or 2E3 or 2E-3. I just can't find a way to get the decimal precision I would like and Setprecision(4) should give me 4 places past the decimal but it doesn't work(I would like for every thing to be in engeering mode.) Help!
David
|
|
|
|
|
You will have to manage the data yourself, Win32 does not provide any extra processing for numbers and things like that.
If you simply want the data to be displayed in a particular format you can wait for the edit control to lose focus then reformat the data yourself from the parent control.
However if you want to limit the characters that the user can type in and the format of their text you will have to do something a little more complicated. I would suggest subclassing the edit control to limit these characters.
Before you do that though I would search through this site and the internet, someone else has probably already created a control like this that you could use.
Good Luck
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
So, I figured out what I was doing with the GDI resources and everything works fine in 2000, NT, XP, and 98 SE. The only problem is, I'm getting the GDI resources running out when I run my app on straight up windows 98. Does anyone know what I need to get to be able to update the Straight Up version of 98 to have the GDI fix or whatever in it without having to purchase the SE? I don't want to tell my customers that they have to buy an upgrade to their OS just to use my app.
|
|
|
|
|
Are you sure your GDI objects are not selected into any DC when you're deleting them?
Tomasz Sowinski -- http://www.shooltz.com
"Yields falsehood when preceded by its quotation" yields falsehood when preceded by its quotation.
|
|
|
|
|
Restoring is key...
<br />
CPaintDC dc(this);<br />
CPen *pOldPen;<br />
CPen pPen;<br />
<br />
CPen pPen(PS_SOLID, 1, RGB(0, 0, 255));<br />
<br />
pOldPen = (CPen *) dc.SelectObject(&pPen);<br />
<br />
dc.SelectObject(pOldPen);<br />
<><><><><><><><><><><><><><>
Matthew R. Miller
mattrmiller@computersmarts.net
www.computersmarts.net
|
|
|
|
|
What's the callback function?
When we need the callback function?
|
|
|
|
|
duen wrote:
When we need the callback function?
Usually in response to a homework question.
Todd Smith
|
|
|
|
|
Usually a callback function is to do the same task over and over again but passing it different variables to get different results each time. Like enumerating which fonts are on the users computer.
But callback can be used in more ways then just this.
<><><><><><><><><><><><><><>
Matthew R. Miller
mattrmiller@computersmarts.net
www.computersmarts.net
|
|
|
|
|
Hello all,
How do you create a date class that has the following date output formats--
DDD YYYY
MM/DD/YY
January 1, 2000
Thanks for the help,
Philll
|
|
|
|
|
copy CDate
Though the cough, hough and hiccough so unsought would plough me through,
enough that I o'er life's dark lough my thorough course pursue.
--Stuart Kidd
|
|
|
|
|
|
CDate has all those output formats.
maybe i misunderstood the question... ?
Though the cough, hough and hiccough so unsought would plough me through,
enough that I o'er life's dark lough my thorough course pursue.
--Stuart Kidd
|
|
|
|