|
No, why would you do such an abomination ? Someone has done it as an article already, if you must try to force the issue. Instead, you should use for_each[^], which will allow you to write a function object to define the action you want to take on each object, using C++ instead of trying to hack it into looking like C#.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
sorry I didn't know. But this looks perfect.
I'm glad I asked.
Nick
I'm not an expert yet, but I play one at work. Yeah and here too.
|
|
|
|
|
Ista wrote:
I'm glad I asked.
*grin* Glad to help. Sorry if I seemed rude, I just hate overuse of macros
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Hi!
How to change the screen cursor with a custom cursor?
I don't want to change the cursor into my main window, but for all applications, wherever the cursor is.
Thks in advance!
Appstmd
http://www.atlence.com
|
|
|
|
|
Atlence wrote:
...but for all applications, wherever the cursor is.
Wouldn't you need SetCapture() for this?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
This function doesn't work, because it changes only the cursor when it is over my application. I want to change the cursor even if the cursor is out of my window application!
Thks in advance!
Appstmd
http://www.atlence.com
|
|
|
|
|
Normally, only the window under the mouse receives WM_SETCURSOR messages. SetCapture() ensures that your window receives WM_SETCURSOR messages without regard to the position of the mouse cursor. That said, is your window receiving WM_SETCURSOR messages even when the mouse is over other windows?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
I call SetCursor () function in my OnInitDialog. But my window only receives WM_SETCURSOR messages when the cursor is over it. Even the controls into my window doesn't receive this message!
Thks in advance!
Appstmd
http://www.atlence.com
|
|
|
|
|
This is just a guess but I think you would call SetCursor() in response to each WM_SETCURSOR received. Doing it once in OnInitDialog() is not sufficient. Have you searched CP and Googled for examples?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
Hi all,
I wrote an SMTP sink based on Microsoft's KB288098 sample ("How to use SMTP Transport Events to Add a Disclaimer to Outgoing SMTP Messages"). I've now successfully modified the sample so my sink gets called when a new email comes in (via IMailTransportSubmission::OnMessageSubmission). I started off creating a small log file in the otherwise empty function--I can confirm my sink gets called.
Now...the function receives a pointer to an IMailMsgProperties. I need to get to any attachment to save it/them locally to the hard drive (as well as retrieve the sender's name and email address). I don't care about getting the subject line or the message body.
I'm afraid my ATL/COM knowledge is severely limited at this point. Given nothing but this interface (IMailMsgProperties), how do I get to these values?
|
|
|
|
|
...what I must add is that I've managed to save the raw content of the email with IMailMsgProperties::CopyContextToFile(), but this gives me the exact same content as the .eml file that gets created under c:\inetpub\mailroot\drop...
Is there anything that will let me retrieve individual properties like sender name and email, and (in particular) the *decoded* version of any MIME or Base64 attachment?
|
|
|
|
|
For future reference (for anyone who might come across this):
The solution to retrieving the subject line, sender, etc lies in GetStringA(). Getting the decoded attachments, if any, lies in IBodyParts/IBodyPart->SaveToFile().
|
|
|
|
|
Hello:
I need to mux two mono audio pcm inputs into one stereo output. Does anyone have a simple DirectShow sample code that I can follow? Many Thanks.
Best Wishes,
Taiwu
|
|
|
|
|
We have a imaging system application with a combination of COM components, extension dll and stand alone executables. Do we have a way of profiling the thread interaction at run time. Are there any tools available for this. My need is to do a profiling of thread interaction within and across processes.
Regards
Rajdeep
|
|
|
|
|
is it possible to make a program develpoed in vb.net and another one in c++ and make them communicate with each other using socket programming.if possible,how? Thanks
|
|
|
|
|
Make the vb an activex control.
Tom Wright
tawright915@yahoo.com
|
|
|
|
|
Is the timeout for an automation server a set parameter or something that can be changed. I've written an client and the server keeps popping up a message box that says the server is busy. It has 3 buttons. Retry, Switch to, Cancel. I want to extend that timeout if possible.
Any suggestions?
Thanks
Tom Wright
tawright915@yahoo.com
|
|
|
|
|
Is there a way to create a program that would read a text file and every time it found a space it would replace the space with a line return?
|
|
|
|
|
Sure! Are you using MFC?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
sure, It isn't a difficult thing
read the text to buffer, and chr the space char ' ', then replace it with '\r', OK, output it to file or screen.
Best Regards
|
|
|
|
|
Is it still possible with the console app? I would like to output it to a new file.
|
|
|
|
|
Andrew Admire wrote:
Is it still possible with the console app?
Of course.
Andrew Admire wrote:
I would like to output it to a new file.
Not a problem.
Is this an MFC-based application?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
I do not know how to use MFC so no, I would like it to be straight console app based.
|
|
|
|
|
Andrew Admire wrote:
...I would like it to be straight console app based.
MFC can be used in both GUI and console applications.
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
Ok, then no I would like to use C++.
|
|
|
|