|
Can we Implement Multiple Inheritance in vc++. If yes How.
infotechtata
|
|
|
|
|
|
Even for the class derived using Cobject it doesnt support
infotechtata
|
|
|
|
|
Cobject doenot not support multiple.So it's derived class cannot support multiple inheritance otherwise the previous line will contradict.
if want then go for non Cobject base class
|
|
|
|
|
don't ask for VC++ but for MC++ (managed C++) so...
as Visual C++ is standard complient, multiple inheritence is of course supported.
now, as C++/CLI target is the .NET framework, i think they limited this point to allow MC++ to coexist with other .NET languages.
TOXCCT >>> GEII power [toxcct][VisualCalc]
-- modified at 4:22 Thursday 24th November, 2005
|
|
|
|
|
Hi,
when you resize a column in list control which event gets triggered?
|
|
|
|
|
OnBegintrack and OnEndtrack
|
|
|
|
|
How to add those event handlers?
|
|
|
|
|
<br />
BEGIN_MESSAGE_MAP(GridClass, CListCtrl)<br />
...<br />
<br />
ON_NOTIFY(HDN_BEGINTRACKA, 0, your_OnBegintrack)<br />
ON_NOTIFY(HDN_BEGINTRACKW, 0, your_OnBegintrack)<br />
ON_NOTIFY(HDN_ENDTRACKA, 0, your_OnEndtrack)<br />
ON_NOTIFY(HDN_ENDTRACKW, 0, your_OnEndtrack)<br />
<br />
END_MESSAGE_MAP()<br />
Note, that the control id of the CHeaderCtrl in CListCtrl is always zero;
thus, the second parameter (that is the control filter) in the ON_NOTIFYs is zero.
The "A" and "W" versions are for ANSI and UNICODE (Wide) environment;
in any given program run, only one or the other will become active.
Btw, OnBegintrack receives control, when the user grabs the right-side divider of a column with the mouse (starting resizing). OnEntrack receives control, when the user releases the divider.
The parameters are:
void yourClass::your_OnBegintrack(NMHEADER *nmheader, LRESULT* pResult)
void yourClass::your_OnBegintrack(NMHEADER *nmheader, LRESULT* pResult)
(*nmheader).iItem is the column index from zero.
*pResult should be set to TRUE if you don't allow resizing (TRUE indicates, that you processed the event completely), and FALSE, if you want MFC to finalize resizing.
|
|
|
|
|
No this is not working?
Actually I want to resize a control in list subitem as I increase or decrease
column width.I am handling this in OnCustomDraw() but it is flickering.I want to set SetRedraw() to TRUE and FALSE but in which event should I do that?
|
|
|
|
|
how to display a gif by cximage
|
|
|
|
|
} as far is gif is concern i have used the CPictureEx class , there is good article on code project , few articles on CxImage also
Vikas Amin
Embin Technology
Bombay
vikas.amin@embin.com
|
|
|
|
|
blackeye2004 wrote: how to display a gif by cximage
CxImage is very Heavy Class. it wil add around 200 to 400 kb to your code depending on Option selected. Better use CEnBitmap by Mr Dan.g. it's is nice CBitmap derived class for Popular Image Format.
here is link for that: -
http://www.codeproject.com/bitmap/extendedbitmap2.asp[^]
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
I have studied the article "Serical Communication in Windows".
It talk about the event driven in Com port, but the reading process of demo program is driven by button.
I would like to know how to do event driven in this demo program.
For example: Automatically detect the com port input data and display the data in the Edit box.
Please help!
|
|
|
|
|
Hi,
Check this[^]
If u r planned to implement serial communication in GUI based application then do read,write... operations in separate thread.
Bye
Cool Ju
Dream Ur Destiny
|
|
|
|
|
I would like to know how to implement it in MFC?
Please help!
|
|
|
|
|
you should go to artical and search for authors: konchat, Ramon de klein, Ashish Dhar. I think you will find many choices for you. I got problem like you a month ago. Cheers.
VC++2003 is not easy to learn than VB or builder C++
MilkyWay
|
|
|
|
|
I tried to post on CodeProject today but "Too many users are trying to ... the server" so i posted the same problem on CodeGuru.com also. My problem is that in linux as super block of ext2 file system is placed in 2nd block of floppy which starts at 1024 and also name of file sytem is written on 57th and 58th bytes of super block so I have written following code to check the file system on floppy but this code is not giving me any output. Can anyone tell me what is problem.
HANDLE fp;<br />
short int data = 0;<br />
DWORD count;<br />
fp = CreateFile ("\\\\.\\a:",GENERIC_READ,FILE_SHARE_READ,NULL,OPEN_ALWAYS,0,NULL);<br />
SetFilePointer(fp,1024+56,NULL,FILE_BEGIN);<br />
ReadFile(fp,&data,2, &count, NULL);
cout <<data;
We Believe in Excellence
|
|
|
|
|
Good morning.
The argument to SetFilePointer() HAS to be an even multiple of the sector size. In your case (a diskette), the sector size is 512.
In fact, ALL operations on a disc device is done on one (or more) complete sector(s) at the time. This goes for seek, read and write.
So:
First, set the file pointer to an even mutiple of 512, in this case it will be 1024.
Then, read a complete (or more) sector(s). A sector is the smallest bit of information a disk device can handle.
Try this:
<br />
HANDLE fp;<br />
short int data = 0;<br />
DWORD count;<br />
unsigned char buffer[512];<br />
fp = CreateFile ("\\\\.\\a:",GENERIC_READ,FILE_SHARE_READ,NULL,OPEN_ALWAYS,0,NULL);<br />
SetFilePointer(fp,1024,NULL,FILE_BEGIN);<br />
ReadFile(fp,buffer,512, &count, NULL);
data = *(buffer + 56);<br />
cout <<data; <br />
Kakan
-- modified at 1:57 Thursday 24th November, 2005
|
|
|
|
|
Thanks Mr. Kakan
for helping me every time. It solved my problem.
We Believe in Excellence
|
|
|
|
|
Hello Aqueel.
You'r welcome.
I glad to be able to help. Don't hesitate to ask again, if you get into trouble.
Kind regards
Kakan.
|
|
|
|
|
1. How can I display an image, like an image editor, in full screen mode?
2. What is the fastest method displaying an image (both in window or in full screen)? Some programs work much faster than others; scrolling an image takes much longer with some programs than with others.
Thanks
|
|
|
|
|
Vancouver wrote: . How can I display an image, like an image editor, in full screen mode?
is CDC::StretchBlt is of any help
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
is CDC::StretchBlt is of any help
StretchBlt is a different issue. In the meantime I found that both SetWindowPos and MoveWindow work with the co-ordinates (0,0) as well (I had thought that would be rejected).
However, this is probably no help for my original problem: performance.
|
|
|
|
|
is there anybody that know how to connect, when i enter matrik no at client side then at the admin side the statistic graph will increase everytime i enter the number. only admin can see this statistic.. please anybody know?
|
|
|
|