 |
 | HOW TO ANSWER A QUESTION Chris Maunder | 23:37 12 Jul '09 |
|
 |
Apologies for the shouting but this is important.
When answering a question please:
- Read the question carefully
- Understand that English isn't everyone's first language so be lenient of bad spelling and grammar
- If a question is poorly phrased then either ask for clarification, ignore it, or mark it down. Insults are not welcome
- If the question is inappropriate then click the 'vote to remove message' button
Insults, slap-downs and sarcasm aren't welcome. Let's work to help developers, not make them feel stupid.
cheers, Chris Maunder
The Code Project Co-founder Microsoft C++ MVP
|
|
|
|
 |
 | HOW TO ASK A QUESTION Chris Maunder | 18:19 12 Feb '09 |
|
 |
For those new to message boards please try to follow a few simple rules when posting your question.- Choose the correct forum for your message. Posting a VB.NET question in the C++ forum will end in tears.
- Be specific! Don't ask "can someone send me the code to create an application that does 'X'. Pinpoint exactly what it is you need help with.
- Keep the subject line brief, but descriptive. eg "File Serialization problem"
- Keep the question as brief as possible. If you have to include code, include the smallest snippet of code you can.
- Be careful when including code that you haven't made a typo. Typing mistakes can become the focal point instead of the actual question you asked.
- Do not remove or empty a message if others have replied. Keep the thread intact and available for others to search and read. If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.
- If you are posting source code with your question, place it inside <pre></pre> tags. We advise you also check the "Encode HTML tags when pasting" checkbox before pasting anything inside the PRE block, and make sure "Ignore HTML tags in this message" check box is unchecked.
- Be courteous and DON'T SHOUT. Everyone here helps because they enjoy helping others, not because it's their job.
- Please do not post links to your question in one forum from another, unrelated forum (such as the lounge). It will be deleted.
- Do not be abusive, offensive, inappropriate or harass anyone on the boards. Doing so will get you kicked off and banned. Play nice.
- If you have a school or university assignment, assume that your teacher or lecturer is also reading these forums.
- No advertising or soliciting.
- We reserve the right to move your posts to a more appropriate forum or to delete anything deemed inappropriate or illegal.
cheers, Chris Maunder
The Code Project Co-founder
Microsoft C++ MVP
|
|
|
|
 |
 | Modeless dialog frame sizing in MFC MDI Vaclav_Sal | 1 hr 32mins ago |
|
 |
Could someone more experienced with dialog frame sizing clarify for me how does MFC MDI determines the size of the MDIChildFrame? My modeless dialog is in FormView ( Property Sheet component) and I can re-size that by changing the dialog resource. I am using tabs and the dialog frame follows the largest tab / page. When I use ResizeParentToFit() in OnInitialUpdate of the FromView I end up with a small frame. However, when I skip the ResizeParentToFit() and use ShowWindow(SW_SHOWMAXIMIZED) I get different , large, FormView frame. I stepped thru the ResizeParentToFit() and still do not see where are the view area dimensions coming from. They seems to be the actual dimensions used by ResizeParentToFit() and ShowWindow(SW_SHOWMAXIMIZED) .
What I really want is to maximize the FormView programatically to fit the whole MainFrame. The automatic sizing the dialog frame itself is fine, but not exactly what I want. Any constructive help is as always appreciated. Thanks for your time. Vaclav
|
|
|
|
 |
|
|
 |
 | larger toolbar images josip cagalj | 3hrs 58mins ago |
|
 |
Hi to all. Is it possible to have a 32x32 images on toolbar while keeping 16x16 in menu. I created toolbar resource (IDR_TOOLBAR1) and set it's button size as 32x32 and load it:
if (!m_wndToolBar.CreateEx(this,...) || !m_wndToolBar.LoadToolBar(IDR_TOOLBAR1 )) { ... }
When compiled and started toolbar correctly shows large btn images but menu is also enlarged showing 32x32 item images!? How to have menu images as before (small 16x16)?
My app info: SDI, VS2008 Thanks in advance!
|
|
|
|
 |
 | making a modelessdialog box as modal narayanagvs | 4hrs 4mins ago |
|
 |
Hi,
I have an MDI application.I create an a Modeless dialog on a menu click.I would like to make it behave like a Modal dialog box. How should I do that?
Thanks Satya
Today is a gift, that's why it is called the present.
|
|
|
|
 |
|
 |
You can try disabling the parent of the dialog by using EnableWindow(FALSE).
|
|
|
|
 |
|
 |
Hi,
Thanks for the reply. But I also dont want my mainframe window to receive messages.I want the exact behaviour of DoModal.
Thanks Satya
Today is a gift, that's why it is called the present.
|
|
|
|
 |
|
 |
narayanagvs wrote: I want the exact behaviour of DoModal.
Sorry, I don't understand. If you want 'the exact behaviour of DoModal' then why do you create a Modeless dialog?
Ali
|
|
|
|
 |
|
 |
I just want to know. This is a question asked to me.
Satya
Today is a gift, that's why it is called the present.
|
|
|
|
 |
|
 |
OK, thanks for answering, I don't think I can help you, I hope someone else can.
Ali
|
|
|
|
 |
|
|
 |
|
 |
Just call DoModal [^] member function of the dialog in the, menu message handler.
|
|
|
|
 |
|
 |
Create another dialog class with the dialog resource of your dialog.
Press F1 for help or google it. Greetings from Germany
|
|
|
|
 |
 | VC++2008(graphics)! anassamar | 4hrs 18mins ago |
|
 |
Hi, I am working in VC++2008 environment, Please Could you tell me why when I use the following header file:
#include;
the following error is appeard:
d:\work c++\alg_helbert\alg_helbert\df.cpp(53) : fatal error C1083: Cannot open include file: 'graphics.h': No such file or directory
I want to use the follwing functions: setcolor Graphmode Textmode , lineto ……………!!!!
Thank you
thank you soso
|
|
|
|
 |
|
 |
I think you are trying to compile the code, which was written using turbo c++ compiler? Because
anassamar wrote: 'graphics.h':
and
anassamar wrote: I want to use the follwing functions: setcolor Graphmode Textmode , lineto ……………!!!!
are graphical functions and header file provided in turbo c++ compiler.
|
|
|
|
 |
|
 |
To add to Mohan Ramachandra's reply, this was a proprietary library for the DOS environment. In other words, this was a graphics library for use in DOS programs only, not Windows or anything else. It was also designed and provided by one company - it is not standard, is not a part of C, and not a part of C++.
While you certainly can do graphics for Windows, it is done differently. See here[^] for graphics stuff that is used with windows at the api level, though there is more in knowing when and how to use this stuff. Do note that normally in a windows program, one only draws to a window device context in response to a WM_PAINT message. (If you are using MFC, that would be in OnPaint or OnDraw. )
Graphics and display is different in Windows than it was in DOS. You have a lot of research and reading to do.
Good luck.
Please do not read this signature.
|
|
|
|
 |
 | Compilation errors Aabid | 5hrs 3mins ago |
|
 |
hi friends,
i am using Visual studio 6.0, Windows.
i dowload an opensource project "wput" :: Wput is a command-line ftp-client that looks like wget but instead of downloading, uploads files or whole directories to remote ftp-servers.
http://wput.sourceforge.net/[^]
as i compile the project i got tons of errors,
ftp-ls.c(40) : fatal error C1083: Cannot open include file: 'unistd.h': No such file or directory
unistd.h is not present anywhere in my system.
Any suggestions!
|
|
|
|
 |
|
 |
unistd.h is not present anywhere in my system.
thats why you are getting the error. Find out that file, and set the correct 'include path' in project settings.
|
|
|
|
 |
|
 |
Can you use the pre-compiled binary instead of compiling it?
"I'm willing to admit that I may not always be right, but I am never wrong." - Samuel Goldwyn
|
|
|
|
 |
|
 |
hi
i do not understand what you want to say? can u explain little better
|
|
|
|
 |
|
 |
I want to say that in-order to use the functionality of wput can you just use the binary file instead of compiling it? Or do you need to compile the source code?
"I'm willing to admit that I may not always be right, but I am never wrong." - Samuel Goldwyn
|
|
|
|
 |
|
 |
ok..
i need to compile the source code.
|
|
|
|
 |
|
 |
Have you read the INSTALL file that comes with the source package. It will have the information on how to compile.
"I'm willing to admit that I may not always be right, but I am never wrong." - Samuel Goldwyn
|
|
|
|
 |
|
 |
Aabid wrote: ftp-ls.c(40) : fatal error C1083: Cannot open include file: 'unistd.h': No such file or directory
As the name suggest, unistd.h is a UNIX-like (maybe Linux) specific header. Have you read the compiling instruction on the project's home page? (I guess you may compile it on Windows provided you use, for instance, Cygwin).
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke [My articles]
|
|
|
|
 |