|
Thanks again!
I ended up using the stringstream approach, as our prof is fanatical about us not using "pure" C functions.
You guys are life savers!
Regards,
Bryan
|
|
|
|
|
Your professor is a wise man.
Steve
|
|
|
|
|
|
Thanks for the info, Mike!
I'm a codeproject n00b, but I get the newsletter!
|
|
|
|
|
What are these 'lparam' and 'wparam' ? Where can i get info abt these?
Consider:
BOOL PostMessage(
UINT message,
WPARAM wParam = 0,
LPARAM lParam = 0
);
MSDN says
The content of 'lparam' and 'wparam' parameter depends on the message being posted.
What will be the values when mouse is clicked or key is pressed?
Thanks in Advance.
|
|
|
|
|
LameThought wrote: What are these 'lparam' and 'wparam' ?
They are message-specific values. Some messages use one, the other, both, or neither.
LameThought wrote: Where can i get info abt these?
MSDN, CP, Google.
LameThought wrote: What will be the values when mouse is clicked or key is pressed?
Again, it all depends on the specific message you are inquiring about.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Now, i want to Set Focus for Edit Box in Dialog using PostMessage, then what will be the values of both?
|
|
|
|
|
Use the SetFocus() function for this.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
In a dialog, use WM_NEXTDLGCTRL which automagically handles the subtleties in how dialogs handle focus. More from Raymond: Clickety[^]
|
|
|
|
|
You should use SetFocus API in this case as David said earlier.
If you see documentation for WM_SETFOCUS , it will tell you, what should be values passed, as wParam and lParam .
It applies to all windows messages.
|
|
|
|
|
I think you will find WPARAM is a WORD and LPARAM is a long. MSDN is right, they are generic parameters, what they mean changes according to what the message is. MSDN will tell you what they mean in each instance, you just need to find the help for the message you're after.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Christian Graus wrote: I think you will find WPARAM is a WORD and LPARAM is a long.
And I thought I was old
WPARAM and LPARAM are both pointer size these days - UINT_PTR and LONG_PTR, respectively.
Mark
"If you can dodge a wrench, you can dodge a ball."
|
|
|
|
|
where con i find example vc++ programs so that i can learn multithreading
|
|
|
|
|
See here.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
The best place to start is here[^].
"It's supposed to be hard, otherwise anybody could do it!" - selfquote "High speed never compensates for wrong direction!" - unknown
|
|
|
|
|
|
Dear frineds i ve created an exe project in MFC. now my problem is how to hide the dialog box during runtime?
is there anyway to do that? if so pls let me know.
thanks(in anticipation)
Malini Nair
|
|
|
|
|
this->ShowWindow(SW_HIDE);
|
|
|
|
|
Hi,
Does anyone knowes how can I obtain the virtual memory size of the process I'm running in?
Thanks,
|
|
|
|
|
How about VirtualQueryEx() ?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
|
hi all,
I have a series of JPEG file coming from a source. I have to create a MPEG file from the series of JPEG file, which can be played in Media Player. How can I do this. What algorith i have to use or else i have to use COM and ActiveX control for the same. Can u give any idea regarding this.
Thanks and Regards
Yudhisthira Attry
|
|
|
|
|
Unless you have an MPEG-1 encoder available, you'll need to understand MPEG-1 compression.
The MPEG Home Page[^]
Which part is giving you trouble?
Mark
"If you can dodge a wrench, you can dodge a ball."
|
|
|
|
|
hi,
I m not understanding how to start that. how to take JPEG for converting MPEG-1. which encoder i have to use and how i have to use. please help me.
i never did such type of programming.
thanks
Yudhisthira Attry
|
|
|
|
|
There's several steps involved - reading the jpeg, decompressing the jpeg, compressing the jpeg
in mpeg format, and writing the mpeg file.
Windows has ways to read/decompress the JPEGs no problem...
Converting video frames to MPEG-1 requires an encoder which you can find/buy from 3rd party
vendors or write your own if you can learn the specification (I gave you the link).
Windows doesn't include an MPEG-1 encoder due to licensing.
If you choose to not write your own encoder, a google search for "MPEG-1 encoder" may help.
Mark
"If you can dodge a wrench, you can dodge a ball."
|
|
|
|