|
Don't forget to include the following codes:
#ifdef _AFXDLL
#define COMPILE_MULTIMON_STUBS
#endif // _AFXDLL
#include "multimon.h"
#pragma warning (default : 4706)
Jack
---------------------------------------------------------------------------------
XD++ MFC/C++ Flow/Diagram Library -- http://www.ucancode.net
|
|
|
|
|
Hi,
I am working on a project on QT and VC++. I need to know after I build the *.dsp and edit the code in VC++, I need to view the members of a certain class. The intellisense refuses to work in this case. I try the Ctrl+T, Ctrl+Atl+space, or even right-click and on the context menu click on List Members. None of this seems to work. Any ideas.
Help greatly appreciated
|
|
|
|
|
Must you use Intellisense? Why not just open the class' .h file? Have you tried deleting the project's .ncb file?
Sitaram Sukumar wrote:
I try the Ctrl+T, Ctrl+Atl+space...
The key combination is Ctrl+Alt+T.
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
Try the following steps:
1.Choose "Insert project to workspace" menu item to insert QT project file to your own project.
2.Then click "File|Save Workspace".
3.Then delete QT project from your project.
Now the intellisense will works.
Jack
---------------------------------------------------------------------------------
XD++ MFC/C++ Flow/Diagram Library -- http://www.ucancode.net
|
|
|
|
|
how do i make the column width in a CListCtrl (report view) fixed (that is not changable by the user!) ?????i want the width fixed!!!!!
cheers.....
"faith, hope, love remain, these three.....; but the greatest of these is love" -1 Corinthians 13:13
|
|
|
|
|
This is what I used in the past, don't know if there's an updated method:
Prevent column resizing
Pssst. You see that little light on your monitor? That's actually a government installed spy camera. Smile and wave to big brother!
|
|
|
|
|
aaaaww......thank u guyz.....itz just what i wanted!!!!!......thank u jack and David!.....
cheers.....
"faith, hope, love remain, these three.....; but the greatest of these is love" -1 Corinthians 13:13
|
|
|
|
|
Handle the HDN_BEGINTRACK notification in the header control's OnChildNotify() method. You'll notice that the resize arrow still shows up. To handle this, override the header control's OnSetCursor() method and return
TRUE.
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
Hi Folks!
I have got a problem hope you people will definately help me..
The problem is i want to display a Grid on screen (MFC App Wizard Application), i did the following
i.e. Draw severel Rectangles to
accomplish the grid like look.
The rectangls are drawn with white 'in' and black 'outer boundry'
[code]
void CSimulationView::OnDraw(CDC* pDC)
{
//Display Squares of width and height 40x40
int x1 = 0 ;
int y1= 0;
for(int i=0; i < 12; i++ )
{
for(int j=0; j < 19; j++ )
{
pDC->Rectangle(x1,y1,x1+40,y1+40);
x1+=40;
}
x1=0;
y1+=40;
}
}
[/code]
The question is how i can change the color of, in of the rectangle and outer boundry(say in color is red and outer boundry color is cyan).
One thing more how to fix the size of my display window.i.e. i want my display window to be 700 pixels wide and 500 pixel high,i.e. user can only minimize or see the window in (700,500) size, he can not resize the display windows..
Hope you prople will sort out my problem..
Reagards, Jinbaba
|
|
|
|
|
jinbabaj wrote:
The question is how i can change the color of, in of the rectangle and outer boundry(say in color is red and outer boundry color is cyan).
The outline is drawn with the current pen, and the inside is filled with the current brush, so to change the colours, select a different pen and brush into the device context using SelectObject().
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
Sizing - Read about WM_GETMINMAXINFO
The WM_GETMINMAXINFO message is sent to a window when the size or position of the window is about to change. An application can use this message to override the window's default maximized size and position, or its default minimum or maximum tracking size.
|
|
|
|
|
Use class CPen to create a cyan pen,such as:
CPen newPen(PS_SOLID,1,RGB(...));
Then select it to DC by call SelectObject of CDC.
Use class CBrush to create a red brush,such as:
CBrush brush(RGB(255,0,0));
Then select it to DC by call SelectObject of CDC.
Now it will be correct.
Jack
---------------------------------------------------------------------------------
XD++ MFC/C++ Flow/Diagram Library -- http://www.ucancode.net
|
|
|
|
|
I stored the MSOFFICE files in the database, and now I want to read them out and display them in my program.
It's available to get it done by storing them on my local disk first, then read them and display them, but I don't think it's a good idea, so need all you help.
thanks.
|
|
|
|
|
Ok, what I'm trying to do here is change the default WindowProc of a common control by hooking RegisterClassEx using a hooking library. I figured InitCommonControls() does nothing but register the common control classes using RegisterClass(). BUT.. I managed to hook the functions, but I noticed that when I start apps like IE and others, I usually get a few RegisterClassEx calls but for really anomalous classes. To make myself clear, its the progress bar I want to change ("msctls_progress32" or something). So I don't get why I'm not logging the RegisterClassEx() calls for those controls when IE starts. My logical explanation would be that the registering of these classes is somehow global for the system and that its only done once at startup or whenever an app first uses them, but that seems kinda weird, cause then why would an app need to call InitCommonControls() each time before it can use them? :/
Then I have a second issue which has more to do with Windows in general really. I was wondering: When an application is loaded, is a new copy of the dlls it uses always loaded in memory, or does Windows keep like a pool of loaded dll's and if its already loaded the app will just use that dll? Like kernel32.dll or user32.dll for example. Does each app get a fresh copy or do they all use a shared instance? My guess would be they all get their own copy, but then I would think applications would consume more memory than they appear to do.
Thanks in advance for any clarifications.
Kuniva
--------------------------------------------
|
|
|
|
|
Kuniva wrote:
My logical explanation would be that the registering of these classes is somehow global for the system and that its only done once at startup or whenever an app first uses them, but that seems kinda weird, cause then why would an app need to call InitCommonControls() each time before it can use them?
Classes are registered per application instance, and are unregistered when the application closes. InitCommonControls() loads the comctl32.dll library, which in turn registers the classes using RegisterClassEx(). Most apps these days use InitCommonControlsEx() and only register the classes that they require. InitCommonControlsEx() can be called multiple times, so IE might only be registering the classes as it needs them. Also, have you checked to see whether it is using the standard progress control and not its own variety?
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
Hmm ok..
First of all, I just checked and the progress control is the normal one registered through InitCommonControlsEx(). Now, I did some testing and came up with some stuff I really can't explain:
First I made a test app that simply consists of a window and it does the following on startup:
INITCOMMONCONTROLSEX icc;
icc.dwSize = sizeof(INITCOMMONCONTROLSEX);
icc.dwICC = ICC_PROGRESS_CLASS;
InitCommonControlsEx(&icc);
Now my hooking app logs both InitCommonControlsEx() and RegisterClassEx(). When I run my test app, I get a log for InitCommonControlsEx() just as I should PLUS a call to RegisterClassEx() (for the progress control). Now the weird thing is, in my hooking app I also log the lpszClassName member of the WNDCLASSEX structure for the RegisterClassEx() function. For my test app I get "PROGRESS"... ???? I mean.. wth is going on, isn't it supposed to be "msctls_progress32" or something?
Now, another weird thing. As I've said I checked the class of the IE progress bar by using Spy++ and it's msctls_progress32. Now the thing is, when I have my hooking app running, then start IE, I DO log two RegisterClassEx() calls but NO InitCommonControlsEx() calls? The ones I do log are the following:
RegisterClassExA() - CicMarshalWndClass
RegisterClassExA() - IMMIF UI
Now, am I right to conclude from this that the "Common progressbar" control IS NOT of class msctls_progress32 but just.. PROGRESS? However, that's impossible because I checked commctrl.h and there it's declared as follows:
#ifndef NOPROGRESS
#ifdef _WIN32
#define PROGRESS_CLASSA "msctls_progress32"
#define PROGRESS_CLASSW L"msctls_progress32"
#ifdef UNICODE
#define PROGRESS_CLASS PROGRESS_CLASSW
#else
#define PROGRESS_CLASS PROGRESS_CLASSA
#endif
#else
#define PROGRESS_CLASS "msctls_progress"
#endif
I am seriously confused about all this and any clarification would be wonderful. Thanks.
Kuniva
--------------------------------------------
|
|
|
|
|
Are you hooking both RegisterClassExA() AND RegisterClassExW()? And you might like to hook RegisterClass() as well, just to make sure...
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
I'm trying to calculate the bounding box for a string. Whenever the string contains asian script (Kanji/Hiragana/Katakana in this case), the calculated rectangle is not wide enough to contain the rendered text.
Is there a trick I should know to make this work?
I'm building my application with UNICODE support.
Nevermind me. I'm an idiot.
--
Schni Schna Schnappi! Schnappi Schnappi Schnapp!
|
|
|
|
|
If you don't mind, could you share your idiocy? I'm working on a multilingual app that includes support for Japanese, and if you came across something interesting, I'd like to know. Thanks!
Software Zen: delete this;
|
|
|
|
|
There was nothing to it really. I'm laying out a series of texts, in my own combobox implementation (since the system supplied one doesn't allow for easy tweaking). In "automatic mode", I have it resize the width dynamically according to the longest entry. What I did wrong was that for each string S in the list, I always measured the first string.
(Jörgen, not logged in. I wish the DNS would stop screwing around )
|
|
|
|
|
I bet $10US that you had the wrong font selected into the DC. ? But yes, please share what was going wrong.
Chris Richardson
|
|
|
|
|
Heh, no. That was the first thing I checked, because I've been burnt by that one before.
See reply to Gary if you're really interested in how stupid I can be.
(Jörgen, not logged in)
|
|
|
|
|
Jörgen Sigvardsson wrote:
Nevermind me. I'm an idiot.
Yeah, we all know that But please tell us what you did this time!
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
Please see my reply to Gary for an insight into the idiot's mind.
(Jörgen, not logged in)
|
|
|
|
|
I've heard two set of stories each saying the opposite. Which one is true?
If it turns out that both versions can be on the same machine, what's the installation procedure like?
Thanks for any insight into this matter.
William
Fortes in fide et opere!
|
|
|
|