|
Why not just use GetWindow(GW_CHILD) on the mdiframe window, then call GetWindow(GW_HWNDNEXT) for all of its siblings which should be MDI children as well. This should be a small loop.
|
|
|
|
|
Hi all,
I used a ActiveX in my program, one of method in ActiveX appear a MessageBox, i wanna send a message for closing that ...
I wrote it after using of the method:
m_Control.Method() // MessageBox() appeared !
SendMessage( WM_KEYDOWN, 13, 0 );
But it doesn't work, how can do that ?
HELP ME
My month article: Game programming by DirectX by Lan Mader.
Please visit in: www.geocities.com/hadi_rezaie/index.html
Hadi Rezaie
|
|
|
|
|
You will not be able to do it from the same thread that you called message box from unless you hook the creation of the message box and subclass the message box, because MessageBox is a modal function. The processing from the message box function will not continue until the Message box window is closed..
|
|
|
|
|
|
Alternatively, you could do a PostMessage (WM_COMMAND, nCode); where nCode is an applicable value such as IDOK, IDCANCEL, etc. In either case, this would need to be done from a separate thread (as pointed out earlier).
/ravi
"There is always one more bug..."
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
Always is message WM_PAINT (for parent window) sent before message WM_PAINT (for child windows). But I have in OnPaint function(parent window) some drawing code which must redraw childwindows!
for example : You clicked on control (with flag WS_DISABLE => ). App in WM_LBUTTONDOWN(parent window <= control has WS_DISABLE) drow red rectangle on place where you clicked. Next you resizeing/moving windows. Windows call WM_PAINT (for parent window) next for control => If OnPaint (parent window) drow below control you dont see anything
LWB
|
|
|
|
|
There are two things that you could do.
1. Tell the child control not to paint itself at all at the time you are interested in, in your WM_PAINT handler by calling ::ValidateRect(hWndChild, NULL). This will validate the invalid region of your child control, and Windows will never generate a WM_PAINT message for the child.
2. Right before the code that you want to paint the red rectangle or what ever else, force an update of the child window with a call to UpdateWindow(hWndChild), this will force the control to update itself, then you can draw the stuff that you want, and the child will not redraw after that.
|
|
|
|
|
How can i convert my HTML file to rtf file?
Thanks,
Kumar Saurabh
|
|
|
|
|
Just copy and paste the text from IE into Wordpad or Word and save it as an rtf.
Simon
There's one for you, nineteen for me
Sonork ID 100.10024
|
|
|
|
|
Hi Simon,
I don't 'vce to do this manually, but programatically. also i want my html file (with images) to be converted into rtf, not only text. when a HTML file opened in word is saved as rtf, then the conversion is done (this is done by automation) but gif's are not rendered, moreover, if you open the file using wordpad then you won't be able to see any image.
Thnaks,
Kumar Saurabh
Software Engneer
Syndew Pvt Ltd
New Delhi
India
|
|
|
|
|
Its kinda of tedious but this one works.
You need to parse the html content urself and construct the rtf, the rtf specs are available here
Actually I have done the other way around by parsing rtf and then converting into html.
For parsing html i think you need to convert it to xhtml or something like that and then construct rtf accordingly.
If you find a easier way do let me know.
Hope this helps.
Cheers
Kannan
|
|
|
|
|
Search Google for "html2rtf". There are a lot of apps, mostly with source. Here is one that is written in perl.
/moliate
|
|
|
|
|
|
is right - what the hell are you talking about ?
Guessing wildly as to what you may be asking, C# is a new lagnuage which owes more to Java than C++, it does not have MFC.
Christian
The tragedy of cyberspace - that so much can travel so far, and yet mean so little.
|
|
|
|
|
I took it to mean "what will happen to MFC after .NET?".
MFC will continue to be around for a good while, so don't worry.
Simon
There's one for you, nineteen for me
Sonork ID 100.10024
|
|
|
|
|
MFC 7.0
It did not go away since C# and C++.NET came out. Micro$oft just made some bug fixes and enhancements and bumped up the version number.
|
|
|
|
|
Hi !
My App has an Explorer-like interface, with a leftview and a rightview. The leftview is a Tree control and the right view is a List control. I overrides the OnContextMenu function in each view to display a popup menu.
I have something weird : when I right click in the right pane, my popup menu appears normally. When I right click in the left pane, the menu doesn't appear. But, if I right click in the left pane, move the mouse with the right button still pressed and after that, release the right button, the pop up menu appears !!!! In my code, I handle the OnContextMenu the same way in the left view as in the right view !
Does anyone know what could be the problem ?
Thank you !
Jerome
|
|
|
|
|
How to make to select graphically, on Bitmap or another graphic format, a nongeometric zone? I would like, in fact, to represent France with these department in a graphic control and to be able to select department with the mouse. I thought of using the CRgn for the zone of selects but I wish resizing dynamically France?
How can I make?
To forgive my English
|
|
|
|
|
In what way would you like to resize the region? Expand and contract or some other way?
There is no support in WIN32 to automatically grow or shrink a region, but there are things that you could probably do. If you give some more information I could suggest a technique.
|
|
|
|
|
I wish to represent France with his departments in a control dockable in an application MFC SDI. Control is thus resizable and I wish to be able to select graphiquemlent each departments with the mouse.
A simple right clic of the mouse on France control returns me the department selected and allows me to work with this one. But I wish that the graphics of France into dockable control may be resizing automatically.(Like the autoresize in ACDSee). I seek just a method to detect on which department clicked.
|
|
|
|
|
I would suggest creating a outline of France with line segments, it could be something very simple with 20 or so line segments.
After you have the line segments, this will be your template for your region outline. You can create a region from these line segments by first Creating a Path. To create a path you need to have a DC that you will draw on and call BeginPath. Then you would draw the line segments on the DC just like you were drawing the outline, but instead of displaying these lines, windows will add these lines to the current Path of the DC. To complete the Path call EndPath.
Now that you have a path you can call PathToRegion on the DC. This will give you the region that you seek.
In order to scale the region, simply start over with the line segments that you have, and it will have a base size say 100x100 pixels. When you get the notification to resize the region to a 200x200 region, calculate the scale difference between the base size and the target size, make a copy of your line segments and scale them by this factor. Then repeat the steps above to create the region.
|
|
|
|
|
Ok, I've tried to install/build STLport on VC6 without sucess .. have gone through STLport forums, etc. and nope.
I know many of you are using STLport and was hopeing if someone who has sucessfully build it could write what they did to get it working.. Where you put the directory when you performed the build, modified #defines or values in any of the STLport config files that needed to be done, what nmake command you ending up typing (nmake params passed in?).
Thanks in advance, I've tried several things and am still trying new things .. but if somebody already has the answer ...
Travis D. Mathison ---
--- After three days without programming, life becomes meaningless ...
|
|
|
|
|
As I recall I trawled the support groups to no avail, reread the docs and realised I needed to change a #define, then all was well. I don't recall the details though - I'd suggest a thorough read of the instructions, because I know that's the step I assumed I could gloss over.
Christian
The tragedy of cyberspace - that so much can travel so far, and yet mean so little.
|
|
|
|
|
Lol, yep Christian .. sure enough I read over it a little more carefully and I'm now up and running ready to go!
Travis D. Mathison ---
--- After three days without programming, life becomes meaningless ...
|
|
|
|
|
I want to debug my ActiveX ,How can I do that?
Mazy
"So,so you think you can tell,
Heaven from Hell,
Blue skies from pain,...
How I wish,how I wish you were here." Wish You Were Here-Pink Floyd-1975
|
|
|
|