|
I compile my (any) WTL Project with following settings:
Project/Settings/C++/Calling Convension: __stdcall.
In release configuration I'm forcedly compile with Debug Run-time library (instead release lib; Project/Settings/C++/Use run-time library),
else : "The instruction at ... referenced memory at ... . Memory could not be read" - with any release lib - single threaded, multithreaded, multithreaded DLL.
Thanx for any help.
|
|
|
|
|
Hi,
I've got to develop a snap-in for the Microsoft Management Console (mmc). I dont have documentation to do that. If someone have a link or an example to help me it would be very apreciate. I usually seen the msdn documentation but it's not very clear in my head and I have trouble with the example.
Thanx for helping me !!!
|
|
|
|
|
I've wrote one...
If it's still actuelle, write me - reznitskiy@softlab.ru
|
|
|
|
|
The Microsoft Platform SDK has numerous code samples for Snap-ins.
|
|
|
|
|
The context menu is simply popup by right clicking the mouse. That's the system default that I don't want it.
|
|
|
|
|
subclass it and trap the right mouse click event and do nothing in it
seems the easiest way to me
mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them
|
|
|
|
|
As we all know, forward declarations are necesary to implement circular references, like below:
struct A;
struct B
{
A * a;
};
struct A
{
B * b
};
My problem is, how do i deal with this using templates? The following pice of code is a syntax error in VC++ 6.0:
template<class c="">
struct A;
template<class c="">
struct B
{
A<c> * a;
};
template<class c="">
struct A
{
B<c> * b
};
Does anyone know th correct syntax?
Jonas Pettersson
|
|
|
|
|
Hmm, this discussion group does not seem to support brackets, they didn't get posted. I'll re-write the question using parenthesis as brackets...
------------------------------------------------------------------------------------------
As we all know, forward declarations are necesary to implement circular references, like below:
struct A;
struct B
{
A * a;
};
struct A
{
B * b
};
My problem is, how do i deal with this using templates? The following pice of code is a syntax error in VC++ 6.0:
template(class C)
struct A;
template(class C)
struct B
{
A(C) * a;
};
template(class C)
struct A
{
B(C) * b
};
Jonas
|
|
|
|
|
I don't get template-related syntax errors when compiling the code in VC6 after simply changing the parentheses to brackets...there is a missing semi-colon after B<c>* b in struct A, but other than that, no problems. (I'm able to create instances of the structs, too; link and running is no problem.)
Walter Gildersleeve
Freiburg, Germany
walter.gildersleeve@pe-gmbh.de
|
|
|
|
|
Hi there,
I am trying to add a small table to my MFC application. I want this to be kind
of like Excel cells, except for I don't want to use Excel. I want to be able to
draw the border lines and also be able to edit the code within each cell.
Being able to extend the width is not necessarily an issue.
Is this possible? What class should I subclass from? I tried using CRichEditView
and CEditView since they seem to be the only ones that allow editing, but drawing
on these wasn't possible, at least within my knowledge.
Could you give me some tip on this.
|
|
|
|
|
You need Chris Maunder's grid control, available on this site. ( at least I seem to recall it was Chris's )
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
or u could subclass a listview control to allow editing in any cell
mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them
|
|
|
|
|
I am trying to get some kind of multiline on my CButton. I am using this to center my text:
case vxCBMiddleCenter:
if (m_bMultiLine == TRUE)
{
pDC->DrawText (Caption, ControlRect, DT_WORDBREAK);
}
else
{
pDC->TextOut (Window.Width() / 2 - csSize.cx / 2,
Window.Height() / 2 - csSize.cy / 2,
Caption);
}
break;
Of course I have different case's for the other alignments on my CButton. I am using TextOut to write my CString (Caption), but I can't find a way to break to another line if I cross the Rect (Window) bounds. DT_WORDBREAK will work in my CString contains spaces (This is a test...), but how do I get this (ThisIsATest...) to break to the next line?
Thanks,
Chris
|
|
|
|
|
call DrawText with the DT_CALCRECT flag and the width of the button set ... then get the size of the bounding rect ... then figure out (using GetTextExtent) how many chars will fit on a line (u can use the average font char width to get a rough approx) ... then draw the text in 2 or more goes using what will fit on each line
mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them
|
|
|
|
|
Is it possible to split a view so it looks like this:
-----------------
|A |B |
| | |
| | |
| | |
-----------------
|C |
| |
-----------------
view a, b, c,... and can I split view B again, and so on....
if so how???
Peter Marino
|
|
|
|
|
u can split views in very twisted ways ... just check out the reuters terminal software (if you're in the financial markets) ... i've never seen so many splitter windows on one screen but surprisingly it is easy-ish to use
so how to do it? heh ... use CSplitterWnd::Create() instead of CSplitterWnd::CreateStatic() ... then use CSplitterWnd::SplitRow() or CSplitterWnd::SplitColumn() and have fun
mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them
|
|
|
|
|
it doesn't work I get an assert all the time,
SIZE s;
s.cx = 100;
s.cy = 100;
m_SplitterWnd.Create( this, 1, 2, s, pContext );
m_SplitterWnd.SplitColumn( x );
I tried using different values for x
|
|
|
|
|
Does anyone know where to find the source it IRotView, the MSDEV tool for viewing the contents of the running object table? Actually I'd be happy with any rot view app.
Thanks,
Aaron
|
|
|
|
|
Hello,
(1) Does someone know how I can display the Windows dialog for connecting a HDD to the network? (sharing it)
(2) I would also like to know how to display the Properties for a specific map (directory).
Cheers,
Henrik
|
|
|
|
|
Does anyone know how to use the ADO DataGrid Control or has an example on how to use it in Visual C++
|
|
|
|
|
See my home page under Software:
http://userpages.umbc.edu/~bcorfm1
|
|
|
|
|
How i get a control over the GetScrollPos() return values?
|
|
|
|
|
...you can minimize the size of a whole mfc program, for my program, it takes ~1,5 mb just for a small hello world app, grrrr
so my question is : how do i have to setup my project options to minimise the size of the program ?
please help me
|
|
|
|
|
goto the 'general' section and then 'tips' here on codeproject ... there are several articles on exactly what u are looking for
mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them
|
|
|
|
|
Usually the release version is much smaller when options set to MINIMIZE-CODE.
But when you want to have very small code than there is no better way then using raw WinAPI.
( WinAPI "Hello world" is about 25k - so any more question about MFC *ggg* ! )
Greatings Mario ///
----------------------
www.klangwerker.de
mario@klangwerker.de
----------------------
|
|
|
|